diff options
author | mux <mux@FreeBSD.org> | 2002-08-03 16:03:21 +0000 |
---|---|---|
committer | mux <mux@FreeBSD.org> | 2002-08-03 16:03:21 +0000 |
commit | f72ce2f014de34b8615290f44d408be01938dd02 (patch) | |
tree | 767cb1c371d1f8a92f24d3039b035dc1af421bc6 /sbin/mount_ntfs | |
parent | 3b6651b983ed2691da3bbc5b5c4cdc8cf4c65900 (diff) | |
download | FreeBSD-src-f72ce2f014de34b8615290f44d408be01938dd02.zip FreeBSD-src-f72ce2f014de34b8615290f44d408be01938dd02.tar.gz |
Now that the kernel is able to load modules itself,
remove all the code which was trying to do so.
This code was nasty in several ways, it was hiding
the kernel bug where the kernel was unable to properly
load a module, and it was quitting if it wasn't able
to load the module. The consequence is that an ABI
breakage of the vfsconf API would have broken *every*
mount utility.
Diffstat (limited to 'sbin/mount_ntfs')
-rw-r--r-- | sbin/mount_ntfs/mount_ntfs.c | 37 |
1 files changed, 2 insertions, 35 deletions
diff --git a/sbin/mount_ntfs/mount_ntfs.c b/sbin/mount_ntfs/mount_ntfs.c index 5269b86..dfa68e6 100644 --- a/sbin/mount_ntfs/mount_ntfs.c +++ b/sbin/mount_ntfs/mount_ntfs.c @@ -70,13 +70,8 @@ main(argc, argv) { struct ntfs_args args; struct stat sb; - int c, mntflags, set_gid, set_uid, set_mask, error; + int c, mntflags, set_gid, set_uid, set_mask; char *dev, *dir, mntpath[MAXPATHLEN]; -#if __FreeBSD_version >= 300000 - struct vfsconf vfc; -#else - struct vfsconf *vfc; -#endif mntflags = set_gid = set_uid = set_mask = 0; (void)memset(&args, '\0', sizeof(args)); @@ -146,35 +141,7 @@ main(argc, argv) args.mode = sb.st_mode & (S_IRWXU | S_IRWXG | S_IRWXO); } -#if __FreeBSD_version >= 300000 - error = getvfsbyname("ntfs", &vfc); - if(error && vfsisloadable("ntfs")) { - if(vfsload("ntfs")) -#else - vfc = getvfsbyname("ntfs"); - if(!vfc && vfsisloadable("ntfs")) { - if(vfsload("ntfs")) -#endif - err(EX_OSERR, "vfsload(ntfs)"); - endvfsent(); /* clear cache */ -#if __FreeBSD_version >= 300000 - error = getvfsbyname("ntfs", &vfc); -#else - vfc = getvfsbyname("ntfs"); -#endif - } -#if __FreeBSD_version >= 300000 - if (error) -#else - if (!vfc) -#endif - errx(EX_OSERR, "ntfs filesystem is not available"); - -#if __FreeBSD_version >= 300000 - if (mount(vfc.vfc_name, mntpath, mntflags, &args) < 0) -#else - if (mount(vfc->vfc_index, mntpath, mntflags, &args) < 0) -#endif + if (mount("ntfs", mntpath, mntflags, &args) < 0) err(EX_OSERR, "%s", dev); exit (0); |