From: Martin Schanzenbach Date: Thu, 23 Feb 2012 17:41:22 +0000 (+0000) Subject: -ns continuation X-Git-Tag: initial-import-from-subversion-38251~14686 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=eb7ab7a92c1e977ac785ab071e678e438cf80d54;p=oweals%2Fgnunet.git -ns continuation --- diff --git a/src/gns/gnunet-service-gns.c b/src/gns/gnunet-service-gns.c index c0a1317e9..7af545672 100644 --- a/src/gns/gnunet-service-gns.c +++ b/src/gns/gnunet-service-gns.c @@ -160,6 +160,27 @@ shutdown_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) GNUNET_DHT_disconnect(dht_handle); } +void +on_namestore_record_put_result(void *cls, + int32_t success, + const char *emsg) +{ + if (GNUNET_NO == success) + { + GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "records already in namestore\n"); + return; + } + else if (GNUNET_YES == success) + { + GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, + "records successfully put in namestore\n"); + return; + } + + GNUNET_log(GNUNET_ERROR_TYPE_ERROR, + "Error putting records into namestore: %s\n", emsg); +} + /** * Function called when we get a result from the dht * for our query @@ -259,7 +280,7 @@ process_authority_dht_result(void* cls, num_records, rd, signature, - NULL, //cont + &on_namestore_record_put_result, //cont NULL); //cls if (query->answered) @@ -412,7 +433,7 @@ process_name_dht_result(void* cls, num_records, rd, signature, - NULL, //cont + &on_namestore_record_put_result, //cont NULL); //cls if (query->answered)