diff options
author | Christian Grothoff <christian@grothoff.org> | 2012-02-18 18:56:16 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2012-02-18 18:56:16 +0000 |
commit | b4896204368760831aa06842fd9a21e28d78d7b4 (patch) | |
tree | 82371d5f4ef4888ce4f3f8f9d56e2066831d97ab /src/dht | |
parent | 9ee4f609af6f20677857ed5b9c5c1da9affdce8d (diff) | |
download | gnunet-b4896204368760831aa06842fd9a21e28d78d7b4.tar.gz gnunet-b4896204368760831aa06842fd9a21e28d78d7b4.zip |
-avoid using add_continuation if possible
Diffstat (limited to 'src/dht')
-rw-r--r-- | src/dht/dht_api.c | 6 |
1 files changed, 2 insertions, 4 deletions
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) | |||
463 | } | 463 | } |
464 | if (NULL != head->cont) | 464 | if (NULL != head->cont) |
465 | { | 465 | { |
466 | GNUNET_SCHEDULER_add_continuation (head->cont, head->cont_cls, | 466 | head->cont (head->cont_cls, NULL); |
467 | GNUNET_SCHEDULER_REASON_PREREQ_DONE); | ||
468 | head->cont = NULL; | 467 | head->cont = NULL; |
469 | head->cont_cls = NULL; | 468 | head->cont_cls = NULL; |
470 | } | 469 | } |
@@ -719,8 +718,7 @@ GNUNET_DHT_disconnect (struct GNUNET_DHT_Handle *handle) | |||
719 | if (GNUNET_SCHEDULER_NO_TASK != pm->timeout_task) | 718 | if (GNUNET_SCHEDULER_NO_TASK != pm->timeout_task) |
720 | GNUNET_SCHEDULER_cancel (pm->timeout_task); | 719 | GNUNET_SCHEDULER_cancel (pm->timeout_task); |
721 | if (NULL != pm->cont) | 720 | if (NULL != pm->cont) |
722 | GNUNET_SCHEDULER_add_continuation (pm->cont, pm->cont_cls, | 721 | pm->cont (pm->cont_cls, NULL); |
723 | GNUNET_SCHEDULER_REASON_TIMEOUT); | ||
724 | GNUNET_free (pm); | 722 | GNUNET_free (pm); |
725 | } | 723 | } |
726 | if (handle->client != NULL) | 724 | if (handle->client != NULL) |