NFSv4: Translate NFS4ERR_BADNAME into ENOENT when applied to a lookup
authorTrond Myklebust <Trond.Myklebust@netapp.com>
Tue, 18 Oct 2011 23:11:49 +0000 (16:11 -0700)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Tue, 18 Oct 2011 23:13:51 +0000 (16:13 -0700)
commit08ef7bd3bc04261d14d570ac7eaac3eac947b1ba
treecc64173b71d4df4a8da4fd2230ae121828fd5443
parent0c2e53f11a6dae9e3af5f50f5ad0382e7c3e0cfa
NFSv4: Translate NFS4ERR_BADNAME into ENOENT when applied to a lookup

Both LOOKUP and OPEN operations may return NFS4ERR_BADNAME if we send a
an invalid name as a filename argument. As far as the application is
concerned, it just has to know that the file doesn't exist, and so
ENOENT would be the appropriate reply. We should only return EINVAL
if the filename is being used to _create_ a new object on the
remote filesystem.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/nfs4proc.c