aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMartin Schanzenbach <mschanzenbach@posteo.de>2020-07-06 14:36:28 +0200
committerMartin Schanzenbach <mschanzenbach@posteo.de>2020-07-06 14:36:28 +0200
commit50f16c6a4fe992ab25637fb80a67b9d4e59b789a (patch)
tree3a08b6df103df86d1d220b30705aaa03322cb3e0 /src
parent03943a61c9d876f4ea32c9f4875ddd4b46a186af (diff)
downloadgnunet-50f16c6a4fe992ab25637fb80a67b9d4e59b789a.tar.gz
gnunet-50f16c6a4fe992ab25637fb80a67b9d4e59b789a.zip
-fix: variable size in test
Diffstat (limited to 'src')
-rw-r--r--src/transport/gnunet-service-transport.c4
-rw-r--r--src/transport/transport_api_core.c5
2 files changed, 5 insertions, 4 deletions
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c
index 9bdcd64be..207c17f2f 100644
--- a/src/transport/gnunet-service-transport.c
+++ b/src/transport/gnunet-service-transport.c
@@ -727,9 +727,9 @@ handle_send_transmit_continuation (void *cls,
727 stcc->uuid); 727 stcc->uuid);
728 send_ok_msg.header.size = htons (sizeof(send_ok_msg)); 728 send_ok_msg.header.size = htons (sizeof(send_ok_msg));
729 send_ok_msg.header.type = htons (GNUNET_MESSAGE_TYPE_TRANSPORT_SEND_OK); 729 send_ok_msg.header.type = htons (GNUNET_MESSAGE_TYPE_TRANSPORT_SEND_OK);
730 send_ok_msg.bytes_msg = htonl (bytes_payload); 730 send_ok_msg.bytes_msg = htons (bytes_payload);
731 send_ok_msg.bytes_physical = htonl (bytes_on_wire); 731 send_ok_msg.bytes_physical = htonl (bytes_on_wire);
732 send_ok_msg.success = htonl (success); 732 send_ok_msg.success = htons (success);
733 send_ok_msg.peer = stcc->target; 733 send_ok_msg.peer = stcc->target;
734 unicast (stcc->tc, &send_ok_msg.header, GNUNET_NO); 734 unicast (stcc->tc, &send_ok_msg.header, GNUNET_NO);
735 } 735 }
diff --git a/src/transport/transport_api_core.c b/src/transport/transport_api_core.c
index 55647508d..7d4b415bd 100644
--- a/src/transport/transport_api_core.c
+++ b/src/transport/transport_api_core.c
@@ -622,13 +622,14 @@ handle_send_ok (void *cls, const struct SendOkMessage *okm)
622 struct Neighbour *n; 622 struct Neighbour *n;
623 uint32_t bytes_msg; 623 uint32_t bytes_msg;
624 uint32_t bytes_physical; 624 uint32_t bytes_physical;
625 uint16_t success = ntohs (okm->success);
625 626
626 bytes_msg = ntohl (okm->bytes_msg); 627 bytes_msg = ntohs (okm->bytes_msg);
627 bytes_physical = ntohl (okm->bytes_physical); 628 bytes_physical = ntohl (okm->bytes_physical);
628 LOG (GNUNET_ERROR_TYPE_DEBUG, 629 LOG (GNUNET_ERROR_TYPE_DEBUG,
629 "Receiving SEND_OK message, transmission to %s %s.\n", 630 "Receiving SEND_OK message, transmission to %s %s.\n",
630 GNUNET_i2s (&okm->peer), 631 GNUNET_i2s (&okm->peer),
631 ntohl (okm->success) == GNUNET_OK ? "succeeded" : "failed"); 632 success == GNUNET_OK ? "succeeded" : "failed");
632 n = neighbour_find (h, &okm->peer); 633 n = neighbour_find (h, &okm->peer);
633 if (NULL == n) 634 if (NULL == n)
634 { 635 {