qemu-stable
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-stable] [PATCH] rdma: fix error check


From: Jie Yang
Subject: [Qemu-stable] [PATCH] rdma: fix error check
Date: Fri, 23 Aug 2013 16:44:09 +0800

Error message is placed wrong place. It will never be printed to warn the user.

Signed-off-by: Frank Yang <address@hidden>
---
 migration-rdma.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/migration-rdma.c b/migration-rdma.c
index 3d1266f..968fbc1 100644
--- a/migration-rdma.c
+++ b/migration-rdma.c
@@ -1585,12 +1585,8 @@ static int qemu_rdma_post_send_control(RDMAContext *rdma, uint8_t *buf,
 
 
     if (ibv_post_send(rdma->qp, &send_wr, &bad_wr)) {
-        return -1;
-    }
-
-    if (ret < 0) {
         fprintf(stderr, "Failed to use post IB SEND for control!\n");
-        return ret;
+        return -1;
     }
 
     ret = qemu_rdma_block_for_wrid(rdma, RDMA_WRID_SEND_CONTROL, NULL);
-- 
1.8.3.msysgit.0

reply via email to

[Prev in Thread] Current Thread [Next in Thread]