ifdebug
authorChristian Grothoff <christian@grothoff.org>
Tue, 14 Jun 2011 09:59:35 +0000 (09:59 +0000)
committerChristian Grothoff <christian@grothoff.org>
Tue, 14 Jun 2011 09:59:35 +0000 (09:59 +0000)
src/util/client.c
src/util/connection.c

index 6c6db02fede4d4d78b1996ef68ae9125e42e51da..65f6dbc774c3d3ab2e9b663202d8508de6f595c6 100644 (file)
@@ -831,10 +831,11 @@ client_notify (void *cls, size_t size, void *buf)
           return 0;
         }
       /* auto-retry */
+#if DEBUG_CLIENT
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                  "Failed to connect to `%s', automatically trying again.\n",
                  th->sock->service_name);
-
+#endif
       GNUNET_CONNECTION_destroy (th->sock->sock, GNUNET_NO);
       th->sock->sock = do_connect (th->sock->service_name,
                                   th->sock->cfg,
index 28898ab18bd18541b3f970869deafcaf8ea0597b..dae049eeba752104b212fd43fb23453358a0664c 100644 (file)
@@ -1420,17 +1420,13 @@ connect_error (void *cls,
   struct GNUNET_CONNECTION_Handle *sock = cls;
   GNUNET_CONNECTION_TransmitReadyNotify notify;
 
+#if DEBUG_CONNECTION
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              "Transmission request of size %u fails (%d/%s/%u), connection failed (%p).\n",
+              "Transmission request of size %u fails (%s/%u), connection failed (%p).\n",
               sock->nth.notify_size, 
-             (sock->sock != NULL) ? *(int*) sock->sock : -1,
              sock->hostname,
              sock->port,
              sock);
-#if DEBUG_CONNECTION
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              "Transmission request of size %u fails, connection failed (%p).\n",
-              sock->nth.notify_size, sock);
 #endif
   sock->write_task = GNUNET_SCHEDULER_NO_TASK;
   notify = sock->nth.notify_ready;