summaryrefslogtreecommitdiffstats
path: root/sbin/fsck_ifs
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1997-12-20 21:36:58 +0000
committerbde <bde@FreeBSD.org>1997-12-20 21:36:58 +0000
commit65928cad92e38495a5aea3120094f81600cfedad (patch)
treea705f1b074c01477503979ce9dd9cff886999fc9 /sbin/fsck_ifs
parent62ece1adce424ae0cd9266dc2068d1d360da139a (diff)
downloadFreeBSD-src-65928cad92e38495a5aea3120094f81600cfedad.zip
FreeBSD-src-65928cad92e38495a5aea3120094f81600cfedad.tar.gz
Don't attempt to print the statistics for a "clean" preened filesystem
when there isn't even a filesystem. Attempting to print them tended to cause SIGSEGV or SIGFPE depending on how far setup() got before it returned 0. This was broken in the previous revision by removing a return statement that the previous case depended on falling into. PR: 4840 (fixed by this commit) PR: 2537 (possibly fixed by Lite2 merge and later changes. setup() does more checking now)
Diffstat (limited to 'sbin/fsck_ifs')
-rw-r--r--sbin/fsck_ifs/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sbin/fsck_ifs/main.c b/sbin/fsck_ifs/main.c
index fbeb3ee..c4ee7cb 100644
--- a/sbin/fsck_ifs/main.c
+++ b/sbin/fsck_ifs/main.c
@@ -195,7 +195,7 @@ checkfilesys(filesys, mntpt, auxdata, child)
case 0:
if (preen)
pfatal("CAN'T CHECK FILE SYSTEM.");
- /* fall through */
+ return (0);
case -1:
pwarn("clean, %ld free ", sblock.fs_cstotal.cs_nffree +
sblock.fs_frag * sblock.fs_cstotal.cs_nbfree);
OpenPOWER on IntegriCloud