Skip to contentSkip to conversation

Possible dereference in drivers/infiniband/hw/amso1100/c2_cm.c

PATCH New Eric Sesterhenn 1 participant 1 message Sep 26, 2006 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Possible dereference in drivers/infiniband/hw/amso1100/c2_cm.c

hi,

another dereference spotted by the coverity checker (cid #1395) In case we cant alloc the vq_req, we goto bail1, where we call vq_req_free(c2dev, vq_req); which then dereferences vq_req().

drivers/infiniband/hw/amso1100/c2_cm.c renamed from drivers/infiniband/hw/amso1100/c2_cm.c.orig +1 -1
@@ -302,7 +302,7 @@ int c2_llp_accept(struct iw_cm_id *cm_id
 	vq_req = vq_req_alloc(c2dev);
 	if (!vq_req) {
 		err = -ENOMEM;
-		goto bail1;
+		goto bail0;
 	}
 	vq_req->qp = qp;
 	vq_req->cm_id = cm_id;