]> git.decadent.org.uk Git - nfs-utils.git/blobdiff - utils/mount/stropts.c
mount.nfs: make nfs_options2pmap return errors
[nfs-utils.git] / utils / mount / stropts.c
index ec95b78619a2c7ab342bfcb20d0863252d4bd01f..30ac5ae6259034889e6af31695dbd196706295ca 100644 (file)
@@ -450,7 +450,10 @@ static struct mount_options *nfs_rewrite_mount_options(char *str)
                goto err;
        }
 
                goto err;
        }
 
-       nfs_options2pmap(options, &nfs_pmap, &mnt_pmap);
+       if (!nfs_options2pmap(options, &nfs_pmap, &mnt_pmap)) {
+               errno = EINVAL;
+               goto err;
+       }
 
        /* The kernel NFS client doesn't support changing the RPC program
         * number for these services, so reset these fields before probing
 
        /* The kernel NFS client doesn't support changing the RPC program
         * number for these services, so reset these fields before probing