From e238459109bf91ee9f15c5d30b0158527fad8eb5 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Tue, 4 Jan 2011 12:59:15 +0000 Subject: [PATCH] cancel hashing on shutdown --- src/fs/gnunet-service-fs_indexing.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/fs/gnunet-service-fs_indexing.c b/src/fs/gnunet-service-fs_indexing.c index 2e95f454f..363755169 100644 --- a/src/fs/gnunet-service-fs_indexing.c +++ b/src/fs/gnunet-service-fs_indexing.c @@ -22,11 +22,6 @@ * @file fs/gnunet-service-fs_indexing.c * @brief program that provides indexing functions of the file-sharing service * @author Christian Grothoff - * - * TODO: - * - consider doing GNUNET_CRYPTO_hash_file_cancel on active indexing - * jobs during shutdown (currently, shutdown will only happen after - * all of those are done, not sure if this is good or bad) */ #include "platform.h" #include @@ -702,6 +697,8 @@ shutdown_task (void *cls, while (NULL != (pos = indexed_files)) { indexed_files = pos->next; + if (pos->fhc != NULL) + GNUNET_CRYPTO_hash_file_cancel (pos->fhc); GNUNET_free (pos); } cfg = NULL; -- 2.25.1