From: Volker Lendecke Date: Tue, 5 Apr 2016 08:11:44 +0000 (+0200) Subject: lib: Use ctdbd_init_connection in messaging_ctdbd_init X-Git-Tag: talloc-2.1.7~140 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e2d39aefae41da5a5614c5061d2aa30f40c5d65d;p=thirdparty%2Fsamba.git lib: Use ctdbd_init_connection in messaging_ctdbd_init Signed-off-by: Volker Lendecke Reviewed-by: Ralph Boehme --- diff --git a/source3/lib/messages_ctdbd.c b/source3/lib/messages_ctdbd.c index 48563a832cd..a61c7739577 100644 --- a/source3/lib/messages_ctdbd.c +++ b/source3/lib/messages_ctdbd.c @@ -178,12 +178,20 @@ int messaging_ctdbd_init(struct messaging_context *msg_ctx, return ENOMEM; } - ret = ctdbd_messaging_connection(ctx, lp_ctdbd_socket(), - lp_ctdb_timeout(), &ctx->conn); + ret = ctdbd_init_connection(ctx, lp_ctdbd_socket(), + lp_ctdb_timeout(), &ctx->conn); if (ret != 0) { - DEBUG(10, ("ctdbd_messaging_connection failed: %s\n", - strerror(ret))); + DBG_DEBUG("ctdbd_init_connection failed: %s\n", + strerror(ret)); + TALLOC_FREE(result); + return ret; + } + + ret = register_with_ctdbd(ctx->conn, MSG_SRVID_SAMBA, NULL, NULL); + if (ret != 0) { + DBG_DEBUG("Could not register MSG_SRVID_SAMBA: %s\n", + strerror(ret)); TALLOC_FREE(result); return ret; }