diff --git a/noice.c b/noice.c index 8eeb7d14..81df9075 100644 --- a/noice.c +++ b/noice.c @@ -567,6 +567,13 @@ redraw: /* Clean screen */ erase(); + /* Strip trailing slashes */ + for (i = strlen(path) - 1; i > 0; i--) + if (path[i] == '/') + path[i] = '\0'; + else + break; + DPRINTF_D(cur); DPRINTF_S(path);