From: Christian Grothoff Date: Sat, 9 Jun 2012 19:42:51 +0000 (+0000) Subject: -zero out X-Git-Tag: initial-import-from-subversion-38251~13200 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=4ff018860eee381464ba10f6f9eb3247fb63b8fe;p=oweals%2Fgnunet.git -zero out --- diff --git a/src/core/core_api.c b/src/core/core_api.c index 5c16adeae..c3dc4c9ec 100644 --- a/src/core/core_api.c +++ b/src/core/core_api.c @@ -1301,6 +1301,7 @@ GNUNET_CORE_notify_transmit_ready (struct GNUNET_CORE_Handle *handle, int cork, GNUNET_assert (notify_size + sizeof (struct SendMessage) < GNUNET_SERVER_MAX_MESSAGE_SIZE); th = &pr->th; + memset (th, 0, sizeof (struct GNUNET_CORE_TransmitHandle)); th->peer = pr; th->get_message = notify; th->get_message_cls = notify_cls; @@ -1335,6 +1336,7 @@ GNUNET_CORE_notify_transmit_ready_cancel (struct GNUNET_CORE_TransmitHandle *th) GNUNET_CONTAINER_DLL_remove (h->control_pending_head, h->control_pending_tail, th->cm); GNUNET_free (th->cm); + th->cm = NULL; } if ((NULL != pr->prev) || (NULL != pr->next) || (pr == h->ready_peer_head)) {