gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r2177 - GNUnet/src/transports


From: durner
Subject: [GNUnet-SVN] r2177 - GNUnet/src/transports
Date: Sat, 8 Oct 2005 04:34:43 -0700 (PDT)

Author: durner
Date: 2005-10-08 04:34:39 -0700 (Sat, 08 Oct 2005)
New Revision: 2177

Modified:
   GNUnet/src/transports/tcp.c
Log:
more debug output

Modified: GNUnet/src/transports/tcp.c
===================================================================
--- GNUnet/src/transports/tcp.c 2005-10-07 22:17:07 UTC (rev 2176)
+++ GNUnet/src/transports/tcp.c 2005-10-08 11:34:39 UTC (rev 2177)
@@ -511,9 +511,15 @@
     mp->size     = len - sizeof(TCPP2P_PACKET);
     mp->tsession = tsession;
 #if DEBUG_TCP
+  {
+    EncName enc;
+    
+    hash2enc(&mp->sender.hashPubKey, &enc);
+    
     LOG(LOG_DEBUG,
-       "tcp transport received %u bytes, forwarding to core\n",
-       mp->size);
+      "tcp transport received %u bytes from %s (CRC %u), forwarding to core\n",
+      mp->size, &enc, crc32N(mp->msg, mp->size));
+  }
 #endif
     coreAPI->receive(mp);
     /* finally, shrink buffer adequately */
@@ -827,9 +833,15 @@
   int success;
 
 #if DEBUG_TCP
-  LOG(LOG_DEBUG,
-      "tcpDirectSend called to transmit %u bytes.\n",
-      ssize);
+  {
+    EncName enc;
+    
+    hash2enc(&tcpSession->sender.hashPubKey, &enc);
+    
+    LOG(LOG_DEBUG,
+        "tcpDirectSend called to transmit %u bytes to %s (CRC %u).\n",
+        ssize, &enc, crc32N(mp, ssize));
+  }
 #endif 
   if (tcp_shutdown == YES) {
 #if DEBUG_TCP
@@ -924,9 +936,15 @@
   int ok;
 
 #if DEBUG_TCP
-  LOG(LOG_DEBUG,
-      "tcpDirectSendReliable called to transmit %u bytes.\n",
-      ssize);
+  {
+    EncName enc;
+    
+    hash2enc(&tcpSession->sender.hashPubKey, &enc);
+    
+    LOG(LOG_DEBUG,
+        "tcpDirectSendReliable called to transmit %u bytes to %s (CRC %u).\n",
+        ssize, &enc, crc32N(mp, ssize));
+  }
 #endif 
   if (tcp_shutdown == YES) {
 #if DEBUG_TCP





reply via email to

[Prev in Thread] Current Thread [Next in Thread]