From: Christian Grothoff Date: Fri, 27 Jan 2017 16:29:15 +0000 (+0100) Subject: add statistics for packets dropped by cadet due to full buffer X-Git-Tag: taler-0.2.1~275 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=80f33364925f6718673dafaf7f06940c2b06af06;p=oweals%2Fgnunet.git add statistics for packets dropped by cadet due to full buffer --- diff --git a/src/cadet/gnunet-service-cadet-new_core.c b/src/cadet/gnunet-service-cadet-new_core.c index 086337c9a..b5b3b6558 100644 --- a/src/cadet/gnunet-service-cadet-new_core.c +++ b/src/cadet/gnunet-service-cadet-new_core.c @@ -210,7 +210,11 @@ route_message (struct CadetPeer *prev, GCP_2s (prev), GNUNET_i2s (GCP_get_id (dir->hop)), GNUNET_sh2s (&cid->connection_of_tunnel)); - GNUNET_assert (dir->out_rpos == dir->out_wpos); + GNUNET_STATISTICS_update (stats, + "# messages dropped due to full buffer", + 1, + GNUNET_NO); + GNUNET_assert (dir->out_rpos == dir->out_wpos); GNUNET_MQ_discard (env); dir->out_rpos++; if (ROUTE_BUFFER_SIZE == dir->out_rpos)