-fix shutdown issue
authorChristian Grothoff <christian@grothoff.org>
Mon, 22 Aug 2016 12:49:56 +0000 (12:49 +0000)
committerChristian Grothoff <christian@grothoff.org>
Mon, 22 Aug 2016 12:49:56 +0000 (12:49 +0000)
src/statistics/statistics_api.c

index acaa1cc45661482d786a056e35ad56af3dd31a26..f72c8525bbc234d5e9acb1dc115fcbc5eb3ed738 100644 (file)
@@ -921,6 +921,7 @@ GNUNET_STATISTICS_destroy (struct GNUNET_STATISTICS_Handle *h,
     return;
   GNUNET_assert (GNUNET_NO == h->do_destroy); /* Don't call twice. */
   if ( (sync_first) &&
+       (0 != GNUNET_MQ_get_length (h->mq)) &&
        (GNUNET_YES == try_connect (h)) )
   {
     if ( (NULL != h->current) &&