summaryrefslogtreecommitdiffstats
path: root/rpc/rpc-transport
diff options
context:
space:
mode:
Diffstat (limited to 'rpc/rpc-transport')
-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 14b068c05cb..8d9e6474f3c 100644
--- a/rpc/rpc-transport/rdma/src/rdma.c
+++ b/rpc/rpc-transport/rdma/src/rdma.c
@@ -3253,7 +3253,7 @@ __gf_rdma_teardown (rpc_transport_t *this)
priv = this->private;
peer = &priv->peer;
- if (peer->cm_id->qp != NULL) {
+ if (peer->cm_id && peer->cm_id->qp != NULL) {
__gf_rdma_destroy_qp (this);
}