From: Christian Grothoff Date: Tue, 4 Jan 2011 12:59:15 +0000 (+0000) Subject: cancel hashing on shutdown X-Git-Tag: initial-import-from-subversion-38251~19373 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e238459109bf91ee9f15c5d30b0158527fad8eb5;p=oweals%2Fgnunet.git cancel hashing on shutdown --- 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;