diff options
Diffstat (limited to 'src/core/gnunet-service-core.c')
-rw-r--r-- | src/core/gnunet-service-core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/gnunet-service-core.c b/src/core/gnunet-service-core.c index 6053ec082..ac9a015d8 100644 --- a/src/core/gnunet-service-core.c +++ b/src/core/gnunet-service-core.c | |||
@@ -1015,7 +1015,7 @@ handle_peer_status_change (struct Neighbour *n) | |||
1015 | GNUNET_i2s (&n->peer)); | 1015 | GNUNET_i2s (&n->peer)); |
1016 | #endif | 1016 | #endif |
1017 | size = sizeof (struct PeerStatusNotifyMessage) + | 1017 | size = sizeof (struct PeerStatusNotifyMessage) + |
1018 | (n->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information); | 1018 | n->ats_count * sizeof (struct GNUNET_TRANSPORT_ATS_Information); |
1019 | if (size >= GNUNET_SERVER_MAX_MESSAGE_SIZE) | 1019 | if (size >= GNUNET_SERVER_MAX_MESSAGE_SIZE) |
1020 | { | 1020 | { |
1021 | GNUNET_break (0); | 1021 | GNUNET_break (0); |
@@ -1024,7 +1024,7 @@ handle_peer_status_change (struct Neighbour *n) | |||
1024 | n->ats_count, | 1024 | n->ats_count, |
1025 | 0); | 1025 | 0); |
1026 | size = sizeof (struct PeerStatusNotifyMessage) + | 1026 | size = sizeof (struct PeerStatusNotifyMessage) + |
1027 | (n->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information); | 1027 | n->ats_count * sizeof (struct GNUNET_TRANSPORT_ATS_Information); |
1028 | } | 1028 | } |
1029 | psnm = (struct PeerStatusNotifyMessage*) buf; | 1029 | psnm = (struct PeerStatusNotifyMessage*) buf; |
1030 | psnm->header.size = htons (size); | 1030 | psnm->header.size = htons (size); |
@@ -1428,7 +1428,7 @@ handle_client_iterate_peers (void *cls, | |||
1428 | n->ats_count, | 1428 | n->ats_count, |
1429 | 0); | 1429 | 0); |
1430 | size = sizeof (struct PeerStatusNotifyMessage) + | 1430 | size = sizeof (struct PeerStatusNotifyMessage) + |
1431 | (n->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information); | 1431 | n->ats_count * sizeof (struct GNUNET_TRANSPORT_ATS_Information); |
1432 | } | 1432 | } |
1433 | cnm = (struct ConnectNotifyMessage*) buf; | 1433 | cnm = (struct ConnectNotifyMessage*) buf; |
1434 | cnm->header.size = htons (size); | 1434 | cnm->header.size = htons (size); |
@@ -3535,7 +3535,7 @@ handle_pong (struct Neighbour *n, | |||
3535 | n->ats_count, | 3535 | n->ats_count, |
3536 | 0); | 3536 | 0); |
3537 | size = sizeof (struct PeerStatusNotifyMessage) + | 3537 | size = sizeof (struct PeerStatusNotifyMessage) + |
3538 | (n->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information); | 3538 | n->ats_count * sizeof (struct GNUNET_TRANSPORT_ATS_Information); |
3539 | } | 3539 | } |
3540 | cnm = (struct ConnectNotifyMessage*) buf; | 3540 | cnm = (struct ConnectNotifyMessage*) buf; |
3541 | cnm->header.size = htons (size); | 3541 | cnm->header.size = htons (size); |