When clearing a log on failure, not only ask the kernel to ignore an
existing log but to remove it on next mount.
This commit is contained in:
parent
fbca096a2d
commit
bc76b1d5b0
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: wapbl.c,v 1.4 2009/09/13 14:25:28 bouyer Exp $ */
|
||||
/* $NetBSD: wapbl.c,v 1.5 2010/03/06 11:31:40 mlelstv Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2005,2008 The NetBSD Foundation, Inc.
|
||||
@ -34,7 +34,7 @@
|
||||
#define WAPBL_INTERNAL
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: wapbl.c,v 1.4 2009/09/13 14:25:28 bouyer Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: wapbl.c,v 1.5 2010/03/06 11:31:40 mlelstv Exp $");
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <sys/time.h>
|
||||
@ -170,6 +170,7 @@ check_wapbl(void)
|
||||
}
|
||||
pwarn("CLEARING EXISTING JOURNAL\n");
|
||||
sblock->fs_flags &= ~FS_DOWAPBL;
|
||||
sblock->fs_journal_flags = UFS_WAPBL_FLAGS_CLEAR_LOG;
|
||||
sbdirty();
|
||||
ret = FSCK_EXIT_CHECK_FAILED;
|
||||
} else {
|
||||
@ -198,6 +199,7 @@ check_wapbl(void)
|
||||
}
|
||||
pwarn("CLEARING EXISTING JOURNAL\n");
|
||||
sblock->fs_flags &= ~FS_DOWAPBL;
|
||||
sblock->fs_journal_flags = UFS_WAPBL_FLAGS_CLEAR_LOG;
|
||||
sblock->fs_journal_location =
|
||||
UFS_WAPBL_JOURNALLOC_NONE;
|
||||
sbdirty();
|
||||
@ -215,6 +217,7 @@ check_wapbl(void)
|
||||
}
|
||||
pwarn("CLEARING EXISTING JOURNAL\n");
|
||||
sblock->fs_flags &= ~FS_DOWAPBL;
|
||||
sblock->fs_journal_flags = UFS_WAPBL_FLAGS_CLEAR_LOG;
|
||||
sbdirty();
|
||||
ret = FSCK_EXIT_CHECK_FAILED;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user