Index: check.c =================================================================== RCS file: /home/ncvs/src/sbin/fsck_msdosfs/check.c,v retrieving revision 1.10 diff -a -u -r1.10 check.c --- check.c 5 Feb 2004 15:47:46 -0000 1.10 +++ check.c 24 Oct 2006 13:59:29 -0000 @@ -84,7 +84,7 @@ return 8; } - if (skipclean && preen && checkdirty(dosfs, &boot)) { + if (skipclean && (preen || forceskipclean) && checkdirty(dosfs, &boot)) { printf("%s: ", fname); printf("FILESYSTEM CLEAN; SKIPPING CHECKS\n"); ret = 0; Index: ext.h =================================================================== RCS file: /home/ncvs/src/sbin/fsck_msdosfs/ext.h,v retrieving revision 1.10 diff -a -u -r1.10 ext.h --- ext.h 9 Mar 2005 10:10:51 -0000 1.10 +++ ext.h 24 Oct 2006 13:59:29 -0000 @@ -49,6 +49,7 @@ extern int preen; /* we are preening */ extern int rdonly; /* device is opened read only (supersedes above) */ extern int skipclean; /* skip clean file systems if preening */ +extern int forceskipclean; /* skip clean file systems (always) */ extern struct dosDirEntry *rootDir; Index: fsck_msdosfs.8 =================================================================== RCS file: /home/ncvs/src/sbin/fsck_msdosfs/fsck_msdosfs.8,v retrieving revision 1.15 diff -a -u -r1.15 fsck_msdosfs.8 --- fsck_msdosfs.8 10 Feb 2005 09:39:51 -0000 1.15 +++ fsck_msdosfs.8 24 Oct 2006 13:59:29 -0000 @@ -44,7 +44,7 @@ .Op Fl f .Ar filesystem ... .Nm -.Op Fl ny +.Op Fl Cny .Ar filesystem ... .Sh DESCRIPTION The @@ -80,6 +80,8 @@ .Pp The options are as follows: .Bl -tag -width indent +.It Fl C +The file systems marked clean are always skipped (not only in preen mode). .It Fl F Compatibility with the wrapper .Xr fsck 8 Index: main.c =================================================================== RCS file: /home/ncvs/src/sbin/fsck_msdosfs/main.c,v retrieving revision 1.15 diff -a -u -r1.15 main.c --- main.c 10 Feb 2005 09:39:51 -0000 1.15 +++ main.c 24 Oct 2006 13:59:29 -0000 @@ -54,6 +54,7 @@ int preen; /* set when preening */ int rdonly; /* device is opened read only (supersedes above) */ int skipclean; /* skip clean file systems if preening */ +int forceskipclean; /* skip clean file systems (always) */ static void usage(void) __dead2; @@ -63,7 +64,7 @@ fprintf(stderr, "%s\n%s\n", "usage: fsck_msdosfs -p [-f] filesystem ...", - " fsck_msdosfs [-ny] filesystem ..."); + " fsck_msdosfs [-Cny] filesystem ..."); exit(1); } @@ -74,8 +75,11 @@ int ch; skipclean = 1; - while ((ch = getopt(argc, argv, "fFnpy")) != -1) { + while ((ch = getopt(argc, argv, "CfFnpy")) != -1) { switch (ch) { + case 'C': + forceskipclean = 1; + break; case 'f': skipclean = 0; break;