On Fri, Dec 22, 2000, Adrian Chadd wrote:
> I've updated my fsck wrappers patchset to the latest netbsd and freebsd
> fsck patches. I'd appreciate some feedback on them before I run off
> and commit them (with my mentor, of course.)
> For those who aren't in the know, the general idea is that a single wrapper
> program spawns a FS-specific fsck process a la mount and mount_*, making
> multiple-FS support a lot easier. (Think about having fsck_ext2fs, fsck_msdos
> and fsck_ffs doing your FSes on bootup..)
> They can be found at http://www.freebsd.org/~adrian/fsck/ . PLEASE read the
> README before you use them, as there are a few gotchas.

Thanks to some feedback from bp, I found a stupid mistake in my porting.

Here's the patch:

--- fsck.c.orig Sat Dec 23 11:13:30 2000
+++ fsck.c      Sat Dec 23 11:13:34 2000
@@ -501,7 +501,7 @@
                errx(1, "partition `%s' is not of a legal vfstype",
-       if ((vfstype = dktypenames[t]) == NULL)
+       if ((vfstype = fstypenames[t]) == NULL)
                errx(1, "vfstype `%s' on partition `%s' is not supported",
                    fstypenames[t], str);

So now is a problem which I'm sure the NetBSD people came up against.
The fstypenames are names like 4.2BSD, vinum, ISO9660, etc. NetBSD fixed
this by creating a new list 'mountnames[]', which maps the fs type to
a string.


What do people think about doing this as well? It would certainly make things
a little tidier, but every time a new fs comes in the magic autodetection code
will need to be updated (if appropriate, of course.)


Adrian Chadd                    "The main reason Santa is so jolly is
<[EMAIL PROTECTED]>               because he knows where all the bad girls
                                    live." -- Random IRC quote

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to