diff --git a/sbin/fsck_ffs/main.c b/sbin/fsck_ffs/main.c index 642e321fdd35..401ee10f9be3 100644 --- a/sbin/fsck_ffs/main.c +++ b/sbin/fsck_ffs/main.c @@ -272,7 +272,6 @@ checkfilesys(char *filesys) * exit status will cause a foreground check to be run. */ sblock_init(); - bufinit(); if (bkgrdcheck) { if ((fsreadfd = open(filesys, O_RDONLY)) < 0 || readsb(0) == 0) exit(3); /* Cannot read superblock */ diff --git a/sbin/fsck_ffs/setup.c b/sbin/fsck_ffs/setup.c index d69beff879e9..0ae7f1bbb28f 100644 --- a/sbin/fsck_ffs/setup.c +++ b/sbin/fsck_ffs/setup.c @@ -298,6 +298,7 @@ setup(char *dev) (uintmax_t)numdirs * sizeof(struct inoinfo *)); goto badsb; } + bufinit(); if (sblock.fs_flags & FS_DOSOFTDEP) usedsoftdep = 1; else