X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Fnfs%2Fsuper.c;h=9abcd2b329f7357b0af65065613e996b643e1747;hb=7db9cbb3748c46b80e5c99ffa91945b8dd4ed5e5;hp=1b94e3650f5cb343d241d372d0d03d85ed42528d;hpb=2fb5e1e101d1b1c9a1aeca7ad99a02b49241ba7b;p=linux-2.6 diff --git a/fs/nfs/super.c b/fs/nfs/super.c index 1b94e3650f..9abcd2b329 100644 --- a/fs/nfs/super.c +++ b/fs/nfs/super.c @@ -1718,9 +1718,9 @@ nfs_remount(struct super_block *sb, int *flags, char *raw_data) * ones were explicitly specified. Fall back to legacy behavior and * just return success. */ - if ((nfsvers == 4 && options4->version == 1) || - (nfsvers <= 3 && options->version >= 1 && - options->version <= 6)) + if ((nfsvers == 4 && (!options4 || options4->version == 1)) || + (nfsvers <= 3 && (!options || (options->version >= 1 && + options->version <= 6)))) return 0; data = kzalloc(sizeof(*data), GFP_KERNEL);