s3: Fix msg_channel in the cluster case
authorVolker Lendecke <vl@samba.org>
Fri, 20 Apr 2012 09:52:02 +0000 (11:52 +0200)
committerVolker Lendecke <vl@samba.org>
Fri, 20 Apr 2012 11:42:40 +0000 (13:42 +0200)
source3/lib/msg_channel.c

index 65976d1170aeba6b9c01ac8a1e414665d9bf0eca..6b3295fc06d9aa58ccf20620757823520617493f 100644 (file)
@@ -329,16 +329,19 @@ static void msg_read_got_ctdb(struct tevent_req *subreq)
                return;
        }
 
-       ndr_err = ndr_push_struct_blob(
+       ndr_err = ndr_pull_struct_blob(
                &blob, state->rec, state->rec,
-               (ndr_push_flags_fn_t)ndr_push_messaging_rec);
+               (ndr_pull_flags_fn_t)ndr_pull_messaging_rec);
 
        if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
-               DEBUG(0, ("ndr_push_struct_blob failed: %s\n",
+               DEBUG(1, ("ndr_pull_struct_blob failed: %s\n",
                          ndr_errstr(ndr_err)));
                tevent_req_error(req, ndr_map_error2errno(ndr_err));
                return;
        }
+       if (DEBUGLEVEL >= 10) {
+               NDR_PRINT_DEBUG(messaging_rec, state->rec);
+       }
        if (state->rec->msg_type == state->channel->msg_type) {
                tevent_req_done(req);
                return;