diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-12-18 10:31:31 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-12-18 10:31:31 +0000 |
commit | 9e7b7ac944811f00132e7f54dc4a5f583a1326dd (patch) | |
tree | 7a820efff7bce527b197d1915a86a76da1f32fb6 | |
parent | ef70fb51271773df97714f739fe7184d4d3a63b8 (diff) | |
download | gnunet-9e7b7ac944811f00132e7f54dc4a5f583a1326dd.tar.gz gnunet-9e7b7ac944811f00132e7f54dc4a5f583a1326dd.zip |
-fix endianess before printing DEBUG message
-rw-r--r-- | src/dv/dv_api.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/dv/dv_api.c b/src/dv/dv_api.c index e726d9d90..4cd072eb7 100644 --- a/src/dv/dv_api.c +++ b/src/dv/dv_api.c | |||
@@ -330,8 +330,9 @@ handle_message_receipt (void *cls, | |||
330 | return; | 330 | return; |
331 | } | 331 | } |
332 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 332 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
333 | "Received message of type %u from DV service\n", | 333 | "Received message of type %u with %u bytes from DV service\n", |
334 | (unsigned int) msg->type); | 334 | (unsigned int) ntohs (msg->type), |
335 | (unsigned int) ntohs (msg->size)); | ||
335 | switch (ntohs (msg->type)) | 336 | switch (ntohs (msg->type)) |
336 | { | 337 | { |
337 | case GNUNET_MESSAGE_TYPE_DV_CONNECT: | 338 | case GNUNET_MESSAGE_TYPE_DV_CONNECT: |
@@ -639,8 +640,8 @@ GNUNET_DV_send (struct GNUNET_DV_ServiceHandle *sh, | |||
639 | } | 640 | } |
640 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 641 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
641 | "Asked to send %u bytes of type %u to %s\n", | 642 | "Asked to send %u bytes of type %u to %s\n", |
642 | (unsigned int) msg->size, | 643 | (unsigned int) ntohs (msg->size), |
643 | (unsigned int) msg->type, | 644 | (unsigned int) ntohs (msg->type), |
644 | GNUNET_i2s (target)); | 645 | GNUNET_i2s (target)); |
645 | peer = GNUNET_CONTAINER_multipeermap_get (sh->peers, | 646 | peer = GNUNET_CONTAINER_multipeermap_get (sh->peers, |
646 | target); | 647 | target); |