summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra G <raghavendra@gluster.com>2010-08-31 03:09:36 +0000
committerVijay Bellur <vijay@dev.gluster.com>2010-08-31 04:33:33 -0700
commite41b82c5704b0a9caba7c511688c9a152c5f2b0f (patch)
tree06d4ef1894193924b09be8844cba83cc7e5b445c
parente1afe36eb3b006be12e7d7a5b87ff181c6da1250 (diff)
rpc-transport/rdma: free ioq entry even when churning of message fails.
- An ioq entry is added to ioq-list only when it is not processed due to lack of quota. For all other cases, it should be freed to avoid memory leak. Signed-off-by: Raghavendra G <raghavendra@gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 513 (Introduce 0 copy rdma) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=513
-rw-r--r--rpc/rpc-transport/rdma/src/rdma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rpc/rpc-transport/rdma/src/rdma.c b/rpc/rpc-transport/rdma/src/rdma.c
index 601c65df7a0..ceb4ee3f6b4 100644
--- a/rpc/rpc-transport/rdma/src/rdma.c
+++ b/rpc/rpc-transport/rdma/src/rdma.c
@@ -1679,7 +1679,7 @@ __rdma_ioq_churn_entry (rdma_peer_t *peer, rdma_ioq_t *entry)
ret = __rdma_ioq_churn_reply (peer, entry, post);
}
- if (ret > 0) {
+ if (ret != 0) {
__rdma_ioq_entry_free (entry);
}
}