diff options
author | Ingo Molnar <mingo@kernel.org> | 2016-09-22 15:21:48 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-09-22 15:21:48 +0200 |
commit | 7cf0f1426a909ed36a8b349a4a975e0d68b5edad (patch) | |
tree | 0700bb26ceeefb95efc13c3247c04fe7207b509e /fs/nfsd/vfs.c | |
parent | c907420fdaec78b17f59a6011cb5f9d6051c6a35 (diff) | |
parent | 9bf6ffdabdd6e70a0b69d032a0aff091afe1773e (diff) |
Merge branch 'locking/urgent' into locking/core, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'fs/nfsd/vfs.c')
-rw-r--r-- | fs/nfsd/vfs.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c index ba944123167b..ff476e654b8f 100644 --- a/fs/nfsd/vfs.c +++ b/fs/nfsd/vfs.c @@ -1252,10 +1252,13 @@ nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp, if (IS_ERR(dchild)) return nfserrno(host_err); err = fh_compose(resfhp, fhp->fh_export, dchild, fhp); - if (err) { - dput(dchild); + /* + * We unconditionally drop our ref to dchild as fh_compose will have + * already grabbed its own ref for it. + */ + dput(dchild); + if (err) return err; - } return nfsd_create_locked(rqstp, fhp, fname, flen, iap, type, rdev, resfhp); } |