diff --git a/ChangeLog b/ChangeLog index 26ce6f4..2e87740 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ svn - ? - Current directory is assumed when no directory is specified - Size graph uses the apparent size if that is displayed - Items are ordered by displayed size rather than disk usage + - Fixed rpath() bug on '/.' 1.4 - 2008-09-10 - Removed the startup window diff --git a/src/calc.c b/src/calc.c index 325b226..b06c6ba 100644 --- a/src/calc.c +++ b/src/calc.c @@ -101,6 +101,11 @@ char *rpath(const char *from, char *to) { break; } to[j+1] = 0; + /* make sure we do have something left in case our path is / */ + if(to[0] == 0) { + to[0] = '/'; + to[1] = 0; + } /* append 'app' */ if(app[0] != 0) strcat(to, app);