From: Christian Grothoff Date: Sat, 18 Feb 2012 18:56:16 +0000 (+0000) Subject: -avoid using add_continuation if possible X-Git-Tag: initial-import-from-subversion-38251~14816 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b4896204368760831aa06842fd9a21e28d78d7b4;p=oweals%2Fgnunet.git -avoid using add_continuation if possible --- diff --git a/src/dht/dht_api.c b/src/dht/dht_api.c index 31648a405..d53728fa9 100644 --- a/src/dht/dht_api.c +++ b/src/dht/dht_api.c @@ -463,8 +463,7 @@ transmit_pending (void *cls, size_t size, void *buf) } if (NULL != head->cont) { - GNUNET_SCHEDULER_add_continuation (head->cont, head->cont_cls, - GNUNET_SCHEDULER_REASON_PREREQ_DONE); + head->cont (head->cont_cls, NULL); head->cont = NULL; head->cont_cls = NULL; } @@ -719,8 +718,7 @@ GNUNET_DHT_disconnect (struct GNUNET_DHT_Handle *handle) if (GNUNET_SCHEDULER_NO_TASK != pm->timeout_task) GNUNET_SCHEDULER_cancel (pm->timeout_task); if (NULL != pm->cont) - GNUNET_SCHEDULER_add_continuation (pm->cont, pm->cont_cls, - GNUNET_SCHEDULER_REASON_TIMEOUT); + pm->cont (pm->cont_cls, NULL); GNUNET_free (pm); } if (handle->client != NULL)