r4901: a bit more info on nbt packets under high debug level
authorAndrew Tridgell <tridge@samba.org>
Fri, 21 Jan 2005 13:39:33 +0000 (13:39 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:09:05 +0000 (13:09 -0500)
(This used to be commit 9a34af29388d8ca837c670d054a76d1f75098cbd)

source4/libcli/nbt/nbtsocket.c

index 865c542ca80e07fb0c3d552b899862bd496500da..8b212fb5556fa7f502872f7ae38d3cf2e99f96f0 100644 (file)
@@ -83,7 +83,8 @@ static void nbt_name_socket_send(struct nbt_name_socket *nbtsock)
                size_t len;
                
                if (DEBUGLVL(10)) {
-                       DEBUG(10,("Sending nbt packet:\n"));
+                       DEBUG(10,("Sending nbt packet to %s:%d\n", 
+                                 req->dest_addr, req->dest_port));
                        NDR_PRINT_DEBUG(nbt_name_packet, req->request);
                }
 
@@ -156,6 +157,7 @@ static void nbt_name_socket_recv(struct nbt_name_socket *nbtsock)
                return;
        }
        talloc_steal(tmp_ctx, src_addr);
+       blob.length = nread;
 
        packet = talloc(tmp_ctx, struct nbt_name_packet);
        if (packet == NULL) {
@@ -173,7 +175,8 @@ static void nbt_name_socket_recv(struct nbt_name_socket *nbtsock)
        }
 
        if (DEBUGLVL(10)) {
-               DEBUG(10,("Received nbt packet:\n"));
+               DEBUG(10,("Received nbt packet of length %d from %s:%d\n", 
+                         blob.length, src_addr, src_port));
                NDR_PRINT_DEBUG(nbt_name_packet, packet);
        }