fixed recommited off-by one bringing core_api to fail
authorMatthias Wachs <wachs@net.in.tum.de>
Mon, 6 Dec 2010 10:55:14 +0000 (10:55 +0000)
committerMatthias Wachs <wachs@net.in.tum.de>
Mon, 6 Dec 2010 10:55:14 +0000 (10:55 +0000)
src/core/gnunet-service-core.c

index ac9a015d848a6cdc4fd9f8b2aecaa749d4c08302..c9eb8fe6b9e4c11465b2022424815a9331ff63f0 100644 (file)
@@ -3763,7 +3763,7 @@ send_p2p_message_to_client (struct Neighbour *sender,
                             const void *m, size_t msize)
 {
   size_t size = msize + sizeof (struct NotifyTrafficMessage) +
-    (sender->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
+    (sender->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
   char buf[size];
   struct NotifyTrafficMessage *ntm;
   struct GNUNET_TRANSPORT_ATS_Information *ats;
@@ -3776,7 +3776,7 @@ send_p2p_message_to_client (struct Neighbour *sender,
                         sender->ats_count,
                         0);
       size = msize + sizeof (struct NotifyTrafficMessage) +
-       (sender->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
+       (sender->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
     }
 #if DEBUG_CORE
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,