diff -Nurd -x'*~' xdiskusage-1.48.orig/xdiskusage.C xdiskusage-1.48/xdiskusage.C --- xdiskusage-1.48.orig/xdiskusage.C 2004-09-21 01:23:14.000000000 -0400 +++ xdiskusage-1.48/xdiskusage.C 2011-05-15 15:10:21.000000000 -0400 @@ -392,16 +392,16 @@ strncpy(pathbuf, path, 1024); for (int i=0; i<10; i++) { char *p = (char*)fl_filename_name(pathbuf); - int i = readlink(pathbuf, p, 1024-(p-pathbuf)); + int pathlen = readlink(pathbuf, p, 1024-(p-pathbuf)); if (i < 0) { if (errno != EINVAL) { strcat(pathbuf, ": no such file"); - fl_alert(pathbuf); + fl_alert("%s", pathbuf); return 0; } break; } - if (*p == '/') {memmove(pathbuf, p, i); p = pathbuf;} + if (*p == '/') {memmove(pathbuf, p, pathlen); p = pathbuf;} p[i] = 0; path = pathbuf; } @@ -492,7 +492,7 @@ size_t len = strlen (buffer); if (buffer[len-1] != '\n') { - fprintf (stderr, "%s:%d: line too long, skipping it\n", path, line_no); + fprintf (stderr, "%s:%lu: line too long, skipping it\n", path, line_no); // Read until end of line or EOF. while (1) { @@ -510,7 +510,7 @@ ulong size = strtoul(buffer, &p, 10); if (!isspace(*p) || p == buffer) { if (!*p || *p=='#') continue; // ignore blank lines or comments (?) - fl_alert("%s:%d: does not look like du output: %s", path, line_no, p); + fl_alert("%s:%lu: does not look like du output: %s", path, line_no, p); cancelled = 1; continue; }