From 7dd9c45f26ee93d719b2b19dda6ebf5528cbc6e6 Mon Sep 17 00:00:00 2001 From: Olivier Houchard Date: Mon, 20 Aug 2007 15:33:22 +0000 Subject: Some times ago, vfs_getopts() was changed, so that it would set error to ENOENT if the option wasn't provided, instead of setting it to 0. xfs however didn't catch up on this, so it assumed something went bad if vfs_getopts() sets the error to non-zero, and just returns the error. Unbreak xfs mount by just ignoring the error if vfs_getopts() sets the error to ENOENT, as we should have sane defaults. Reviewed by: kan Approved by: re (rwatson) Tested by: rpaulo --- sys/gnu/fs/xfs/FreeBSD/xfs_mountops.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'sys/gnu/fs') diff --git a/sys/gnu/fs/xfs/FreeBSD/xfs_mountops.c b/sys/gnu/fs/xfs/FreeBSD/xfs_mountops.c index 758cdef01adf..8d3ba0ff6066 100644 --- a/sys/gnu/fs/xfs/FreeBSD/xfs_mountops.c +++ b/sys/gnu/fs/xfs/FreeBSD/xfs_mountops.c @@ -131,25 +131,25 @@ _xfs_param_copyin(struct mount *mp, struct thread *td) args->logbufsize = -1; parse_int(mp, "flags", &args->flags, &error); - if (error != 0) + if (error != 0 && error != ENOENT) return error; args->flags |= XFSMNT_32BITINODES; parse_int(mp, "sunit", &args->sunit, &error); - if (error != 0) + if (error != 0 && error != ENOENT) return error; parse_int(mp, "swidth", &args->swidth, &error); - if (error != 0) + if (error != 0 && error != ENOENT) return error; parse_int(mp, "logbufs", &args->logbufs, &error); - if (error != 0) + if (error != 0 && error != ENOENT) return error; parse_int(mp, "logbufsize", &args->logbufsize, &error); - if (error != 0) + if (error != 0 && error != ENOENT) return error; fsname = vfs_getopts(mp->mnt_optnew, "from", &error); -- cgit v1.2.3