always enable RPC debugging with a debug level >= 100.
authorAndrew Tridgell <tridge@samba.org>
Thu, 11 Jun 2009 05:21:29 +0000 (15:21 +1000)
committerAndrew Tridgell <tridge@samba.org>
Fri, 12 Jun 2009 02:23:45 +0000 (12:23 +1000)
This helps with tools where setting the binding string is not
possible, such as net

source4/librpc/rpc/dcerpc.c
source4/librpc/rpc/dcerpc_util.c

index c8add30ef849606e1b3488c3d2b34a7d4bfaecfc..13f649cdd9c9178ee2efc53a1f5035874336b69c 100644 (file)
@@ -114,6 +114,10 @@ _PUBLIC_ struct dcerpc_pipe *dcerpc_pipe_init(TALLOC_CTX *mem_ctx, struct tevent
        ZERO_STRUCT(p->syntax);
        ZERO_STRUCT(p->transfer_syntax);
 
+       if (DEBUGLVL(100)) {
+               p->conn->flags |= DCERPC_DEBUG_PRINT_BOTH;
+       }
+
        return p;
 }
 
index d57cc57e47e83e63797dfb8ddd2c805c8496af0e..4524673449a83e71fcb1b7d1f112305ab0c86253 100644 (file)
@@ -513,6 +513,10 @@ struct composite_context *dcerpc_pipe_auth_send(struct dcerpc_pipe *p,
 
        conn = s->pipe->conn;
        conn->flags = binding->flags;
+
+       if (DEBUGLVL(100)) {
+               conn->flags |= DCERPC_DEBUG_PRINT_BOTH;
+       }
        
        /* remember the binding string for possible secondary connections */
        conn->binding_string = dcerpc_binding_string(p, binding);