summaryrefslogtreecommitdiffstats
path: root/ctdb/ib/ibwrapper.c
diff options
context:
space:
mode:
authorRonnie Sahlberg <ronniesahlberg@gmail.com>2009-05-21 11:49:16 +1000
committerRonnie Sahlberg <ronniesahlberg@gmail.com>2009-05-21 11:49:16 +1000
commit26e1486db7cafa86d9deceb225820631dfeb2a92 (patch)
treec58301360350c1fa609cba5c8cbb3f2662c8e889 /ctdb/ib/ibwrapper.c
parent2fcedf6dac9dd275adbb0017e53547614df29d93 (diff)
downloadsamba-26e1486db7cafa86d9deceb225820631dfeb2a92.tar.gz
samba-26e1486db7cafa86d9deceb225820631dfeb2a92.tar.xz
samba-26e1486db7cafa86d9deceb225820631dfeb2a92.zip
Whitespace changes and using the CTDB_NO_MEMORY() macro changes to
the previous patch. (This used to be ctdb commit d623ea7c04daa6349b42d50862843c9f86115488)
Diffstat (limited to 'ctdb/ib/ibwrapper.c')
-rw-r--r--ctdb/ib/ibwrapper.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/ctdb/ib/ibwrapper.c b/ctdb/ib/ibwrapper.c
index 6a557cbb4d..f6e71687f3 100644
--- a/ctdb/ib/ibwrapper.c
+++ b/ctdb/ib/ibwrapper.c
@@ -852,7 +852,9 @@ static int ibw_wc_recv(struct ibw_conn *conn, struct ibv_wc *wc)
}
if (part->to_read==0) {
- if(pctx->receive_func(conn, part->buf, part->len)) goto error;
+ if (pctx->receive_func(conn, part->buf, part->len) != 0) {
+ goto error;
+ }
part->len = 0; /* tells not having partial data (any more) */
if (ibw_wc_mem_threshold(pconn, part, pctx->opts.recv_threshold))
goto error;
@@ -867,7 +869,9 @@ static int ibw_wc_recv(struct ibw_conn *conn, struct ibv_wc *wc)
/* mostly awaited case: */
if (msglen<=remain) {
- if(pctx->receive_func(conn, p, msglen)) goto error;
+ if (pctx->receive_func(conn, p, msglen) != 0) {
+ goto error;
+ }
p += msglen;
remain -= msglen;
} else {