aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/util/mq.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/util/mq.c b/src/util/mq.c
index 193823c93..cb380de43 100644
--- a/src/util/mq.c
+++ b/src/util/mq.c
@@ -335,7 +335,11 @@ GNUNET_MQ_discard (struct GNUNET_MQ_Envelope *ev)
335unsigned int 335unsigned int
336GNUNET_MQ_get_length (struct GNUNET_MQ_Handle *mq) 336GNUNET_MQ_get_length (struct GNUNET_MQ_Handle *mq)
337{ 337{
338 return mq->queue_length - (GNUNET_YES == mq->in_flight) ? 1 : 0; 338 if (GNUNET_YES != mq->in_flight)
339 {
340 return mq->queue_length;
341 }
342 return mq->queue_length - 1;
339} 343}
340 344
341 345