summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrishna Srinivas <ksriniva@redhat.com>2012-05-18 17:43:49 +0530
committerVijay Bellur <vijay@gluster.com>2012-05-26 00:57:12 -0700
commit994c56a185d1f3e0f0f40f4051f82cdf2c7905b9 (patch)
tree0f6de3283e740a3d4a63c7f0046043e36d524904
parent69392d4daa9df0612630813713ae02a99cc068e0 (diff)
nfs/nlm: nlm-unlock call should reply success in case it is not able to find the lock in the list.
Change-Id: I84b298702c445320082ef03de90c924931f1a1e1 BUG: 822384 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3451 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
-rw-r--r--xlators/nfs/server/src/nlm4.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/xlators/nfs/server/src/nlm4.c b/xlators/nfs/server/src/nlm4.c
index 72f71609a51..7eb95a7a553 100644
--- a/xlators/nfs/server/src/nlm4.c
+++ b/xlators/nfs/server/src/nlm4.c
@@ -1700,19 +1700,22 @@ nlm4_unlock_resume (void *carg)
nlmclnt = nlm_get_uniq (cs->args.nlm4_unlockargs.alock.caller_name);
if (nlmclnt == NULL) {
- gf_log (GF_NLM, GF_LOG_ERROR, "nlm_get_uniq() returned NULL");
+ stat = nlm4_granted;
+ gf_log (GF_NLM, GF_LOG_WARNING, "nlm_get_uniq() returned NULL");
goto nlm4err;
}
cs->fd = fd_lookup_uint64 (cs->resolvedloc.inode, (uint64_t)nlmclnt);
if (cs->fd == NULL) {
- gf_log (GF_NLM, GF_LOG_ERROR, "fd_lookup_uint64() returned NULL");
+ stat = nlm4_granted;
+ gf_log (GF_NLM, GF_LOG_WARNING, "fd_lookup_uint64() returned "
+ "NULL");
goto nlm4err;
}
ret = nlm4_unlock_fd_resume (cs);
nlm4err:
if (ret < 0) {
- gf_log (GF_NLM, GF_LOG_ERROR, "unable to unlock_fd_resume");
+ gf_log (GF_NLM, GF_LOG_WARNING, "unable to unlock_fd_resume");
nlm4_generic_reply (cs->req, cs->args.nlm4_unlockargs.cookie,
stat);