ext2fs: Mark superblock as not modified when written
authorsf <sf@openbsd.org>
Tue, 30 May 2017 10:32:53 +0000 (10:32 +0000)
committersf <sf@openbsd.org>
Tue, 30 May 2017 10:32:53 +0000 (10:32 +0000)
I have seen spurious "file system not clean; please fsck(8)" warnings
during "mount -ur". Set e2fs_fmod = 0 when writing the superblock (as
ffs does).

"Makes sense" deraadt@

sys/ufs/ext2fs/ext2fs_vfsops.c

index 53eaa05..c99cfc7 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: ext2fs_vfsops.c,v 1.98 2017/04/20 14:13:00 visa Exp $ */
+/*     $OpenBSD: ext2fs_vfsops.c,v 1.99 2017/05/30 10:32:53 sf Exp $   */
 /*     $NetBSD: ext2fs_vfsops.c,v 1.1 1997/06/11 09:34:07 bouyer Exp $ */
 
 /*
@@ -1000,6 +1000,7 @@ ext2fs_sbupdate(struct ufsmount *mp, int waitfor)
                error = bwrite(bp);
        else
                bawrite(bp);
+       fs->e2fs_fmod = 0;
        return (error);
 }