Index: head/bin/df/df.c =================================================================== --- head/bin/df/df.c +++ head/bin/df/df.c @@ -254,9 +254,11 @@ rv = 1; continue; } -#ifdef MOUNT_CHAR_DEVS } else if (S_ISCHR(stbuf.st_mode)) { if ((mntpt = getmntpt(*argv)) == NULL) { +#ifdef MOUNT_CHAR_DEVS + xo_warnx( + "df on unmounted devices is deprecated"); mdev.fspec = *argv; mntpath = strdup("/tmp/df.XXXXXX"); if (mntpath == NULL) { @@ -305,8 +307,12 @@ (void)rmdir(mntpt); free(mntpath); continue; - } +#else + xo_warnx("%s: not mounted", *argv); + rv = 1; + continue; #endif + } } else mntpt = *argv;