[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <ca76105264283034a0f3d9d138bded79f5b2f87e.1184798679.git.bfields@citi.umich.edu>
Date: Wed, 18 Jul 2007 18:57:28 -0400
From: "J. Bruce Fields" <bfields@...ldses.org>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: NeilBrown <neilb@...e.de>, nfs@...ts.sourceforge.net,
linux-kernel@...r.kernel.org, andros@...i.umich.edu,
"J. Bruce Fields" <bfields@...i.umich.edu>
Subject: [PATCH 3/5] nfsd: remove unnecessary NULL checks from nfsd_cross_mnt
From: J. Bruce Fields <bfields@...i.umich.edu>
We can now assume that rqst_exp_get_by_name() does not return NULL; so
clean up some unnecessary checks.
Signed-off-by: "J. Bruce Fields" <bfields@...i.umich.edu>
---
fs/nfsd/vfs.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c
index b8da5dd..5c97d0e 100644
--- a/fs/nfsd/vfs.c
+++ b/fs/nfsd/vfs.c
@@ -120,14 +120,14 @@ nfsd_cross_mnt(struct svc_rqst *rqstp, struct dentry **dpp,
mntput(mnt);
goto out;
}
- if (exp2 && ((exp->ex_flags & NFSEXP_CROSSMOUNT) || EX_NOHIDE(exp2))) {
+ if ((exp->ex_flags & NFSEXP_CROSSMOUNT) || EX_NOHIDE(exp2)) {
/* successfully crossed mount point */
exp_put(exp);
*expp = exp2;
dput(dentry);
*dpp = mounts;
} else {
- if (exp2) exp_put(exp2);
+ exp_put(exp2);
dput(mounts);
}
mntput(mnt);
--
1.5.3.rc2
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists