From: Bart Polot Date: Wed, 26 Oct 2016 04:20:57 +0000 (+0000) Subject: - improve logging of CONN_ACK X-Git-Tag: initial-import-from-subversion-38251~39 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=4af6ba201b444853becae1981f07f2ae021397ec;p=oweals%2Fgnunet.git - improve logging of CONN_ACK --- diff --git a/src/cadet/gnunet-service-cadet_connection.c b/src/cadet/gnunet-service-cadet_connection.c index 32ce49fc8..37d55a5b0 100644 --- a/src/cadet/gnunet-service-cadet_connection.c +++ b/src/cadet/gnunet-service-cadet_connection.c @@ -1029,16 +1029,17 @@ send_connection_ack (struct CadetConnection *c, int fwd) { struct GNUNET_CADET_ConnectionACK msg; struct CadetTunnel *t; - size_t size = sizeof (struct GNUNET_CADET_ConnectionACK); + const uint16_t size = sizeof (struct GNUNET_CADET_ConnectionACK); + const uint16_t type = GNUNET_MESSAGE_TYPE_CADET_CONNECTION_ACK; GCC_check_connections (); t = c->t; LOG (GNUNET_ERROR_TYPE_INFO, - "==> { C %s ACK} %19s on conn %s (%p) %s [%5u]\n", - GC_f2s (!fwd), "", GCC_2s (c), c, GC_f2s (fwd), size); + "==> %s ({ C %s ACK} 0) on conn %s (%p) %s [%5u]\n", + GC_m2s (type), GC_f2s (!fwd), GCC_2s (c), c, GC_f2s (fwd), size); - msg.header.size = htons (sizeof (struct GNUNET_CADET_ConnectionACK)); - msg.header.type = htons (GNUNET_MESSAGE_TYPE_CADET_CONNECTION_ACK); + msg.header.size = htons (size); + msg.header.type = htons (type); msg.reserved = htonl (0); msg.cid = c->id;