ctdb-ib: Make infiniband transport compile again
authorAmitay Isaacs <amitay@gmail.com>
Wed, 28 May 2014 00:40:29 +0000 (10:40 +1000)
committerAmitay Isaacs <amitay@samba.org>
Thu, 29 May 2014 01:35:54 +0000 (03:35 +0200)
commitf2ef23cd5f227d2da2f032a2a56fbdd4d105b137
tree6efd6db65ef8c69c1bca4161bc526ed906ae6f38
parenta27e59e8ecb622de826323c048107ab75acd0928
ctdb-ib: Make infiniband transport compile again

Update included header files and fix compilation warnings.

  ib/ibwrapper.c: In function ‘ibw_stop’:
  ib/ibwrapper.c:1015:17: warning: comparison between ‘enum ibw_state_ctx’ and ‘enum ibw_state_conn’ [-Wenum-compare]
     if (ctx->state==IBWC_ERROR || ctx->state==IBWC_CONNECTED) {
                 ^
  ib/ibwrapper.c:1015:43: warning: comparison between ‘enum ibw_state_ctx’ and ‘enum ibw_state_conn’ [-Wenum-compare]
     if (ctx->state==IBWC_ERROR || ctx->state==IBWC_CONNECTED) {

The current logic just seems wrong.  The context of this line and the
error checking in ibw_disconnect() suggest that these comparisons
should use p->state rather than ctx->state, so do that.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
ctdb/Makefile.in
ctdb/ib/config.m4
ctdb/ib/ibw_ctdb_init.c
ctdb/ib/ibwrapper.c
ctdb/ib/ibwrapper_test.c