From d3834ca8024608b1dc7df467405d8a6ed31e8c05 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Mon, 27 Jun 2016 12:20:12 +0000 Subject: add function to obtain mq length --- src/include/gnunet_mq_lib.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/include/gnunet_mq_lib.h') diff --git a/src/include/gnunet_mq_lib.h b/src/include/gnunet_mq_lib.h index 0d201d36d..08e09d5b5 100644 --- a/src/include/gnunet_mq_lib.h +++ b/src/include/gnunet_mq_lib.h @@ -432,6 +432,16 @@ void GNUNET_MQ_discard (struct GNUNET_MQ_Envelope *mqm); +/** + * Obtain the current length of the message queue. + * + * @param mq queue to inspect + * @return number of queued, non-transmitted messages + */ +unsigned int +GNUNET_MQ_get_length (struct GNUNET_MQ_Handle *mq); + + /** * Send a message with the give message queue. * May only be called once per message. -- cgit v1.2.3