gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r37447 - gnunet/src/namestore


From: gnunet
Subject: [GNUnet-SVN] r37447 - gnunet/src/namestore
Date: Sat, 2 Jul 2016 22:12:52 +0200

Author: grothoff
Date: 2016-07-02 22:12:52 +0200 (Sat, 02 Jul 2016)
New Revision: 37447

Modified:
   gnunet/src/namestore/namestore_api.c
Log:
-fix use after free on shutdown

Modified: gnunet/src/namestore/namestore_api.c
===================================================================
--- gnunet/src/namestore/namestore_api.c        2016-07-02 20:09:06 UTC (rev 
37446)
+++ gnunet/src/namestore/namestore_api.c        2016-07-02 20:12:52 UTC (rev 
37447)
@@ -824,7 +824,7 @@
 
   GNUNET_MQ_destroy (h->mq);
   h->mq = NULL;
-  for (ze = h->z_head; NULL != ze; ze = ze->next)
+  while (NULL != (ze = h->z_head))
   {
     /* FIXME: This does not allow clients to distinguish
        iteration error from successful termination! */
@@ -832,7 +832,7 @@
       ze->proc (ze->proc_cls, NULL, NULL, 0, NULL);
     free_ze (ze);
   }
-  for (qe = h->op_head; NULL != qe; qe = qe->next)
+  while (NULL != (qe = h->op_head))
   {
     /* FIXME: This does not allow clients to distinguish
        iteration error from successful termination! */




reply via email to

[Prev in Thread] Current Thread [Next in Thread]