aboutsummaryrefslogtreecommitdiff
path: root/src/mesh
diff options
context:
space:
mode:
authorBart Polot <bart@net.in.tum.de>2011-11-03 15:24:09 +0000
committerBart Polot <bart@net.in.tum.de>2011-11-03 15:24:09 +0000
commit229ebca4f9566b5f46beff710e88ffc45c89787e (patch)
tree07132837ad2ce84f2d50fb0b4ec1ad63a92e3e4f /src/mesh
parent84a70da19fdf98b028b98e23a228e32f591535fe (diff)
downloadgnunet-229ebca4f9566b5f46beff710e88ffc45c89787e.tar.gz
gnunet-229ebca4f9566b5f46beff710e88ffc45c89787e.zip
Disable DHT debug of MESH separately
Diffstat (limited to 'src/mesh')
-rw-r--r--src/mesh/gnunet-service-mesh.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/mesh/gnunet-service-mesh.c b/src/mesh/gnunet-service-mesh.c
index a792884c9..5acaf21b9 100644
--- a/src/mesh/gnunet-service-mesh.c
+++ b/src/mesh/gnunet-service-mesh.c
@@ -69,6 +69,8 @@
69 GNUNET_TIME_UNIT_SECONDS,\ 69 GNUNET_TIME_UNIT_SECONDS,\
70 2) 70 2)
71 71
72#define MESH_DEBUG_DHT GNUNET_NO
73
72/******************************************************************************/ 74/******************************************************************************/
73/************************ DATA STRUCTURES ****************************/ 75/************************ DATA STRUCTURES ****************************/
74/******************************************************************************/ 76/******************************************************************************/
@@ -578,13 +580,17 @@ announce_applications (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
578 announce_applications_task = GNUNET_SCHEDULER_NO_TASK; 580 announce_applications_task = GNUNET_SCHEDULER_NO_TASK;
579 return; 581 return;
580 } 582 }
583#if MESH_DEBUG_DHT
581 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: Starting PUT for apps\n"); 584 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: Starting PUT for apps\n");
585#endif
582 GNUNET_CONTAINER_multihashmap_iterate (applications, &announce_application, 586 GNUNET_CONTAINER_multihashmap_iterate (applications, &announce_application,
583 NULL); 587 NULL);
584 announce_applications_task = 588 announce_applications_task =
585 GNUNET_SCHEDULER_add_delayed (APP_ANNOUNCE_TIME, &announce_applications, 589 GNUNET_SCHEDULER_add_delayed (APP_ANNOUNCE_TIME, &announce_applications,
586 cls); 590 cls);
591#if MESH_DEBUG_DHT
587 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: Finished PUT for apps\n"); 592 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: Finished PUT for apps\n");
593#endif
588 return; 594 return;
589} 595}
590 596
@@ -607,8 +613,10 @@ announce_id (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
607 * - Set data expiration in function of X 613 * - Set data expiration in function of X
608 * - Adapt X to churn 614 * - Adapt X to churn
609 */ 615 */
616#if MESH_DEBUG_DHT
610 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: DHT_put for ID %s started.\n", 617 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: DHT_put for ID %s started.\n",
611 GNUNET_i2s (&my_full_id)); 618 GNUNET_i2s (&my_full_id));
619#endif
612 GNUNET_DHT_put (dht_handle, /* DHT handle */ 620 GNUNET_DHT_put (dht_handle, /* DHT handle */
613 &my_full_id.hashPubKey, /* Key to use */ 621 &my_full_id.hashPubKey, /* Key to use */
614 10U, /* Replication level */ 622 10U, /* Replication level */
@@ -619,7 +627,7 @@ announce_id (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
619 (char *)&my_full_id, /* Data itself */ 627 (char *)&my_full_id, /* Data itself */
620 GNUNET_TIME_absolute_get_forever (), /* Data expiration */ 628 GNUNET_TIME_absolute_get_forever (), /* Data expiration */
621 GNUNET_TIME_UNIT_FOREVER_REL, /* Retry time */ 629 GNUNET_TIME_UNIT_FOREVER_REL, /* Retry time */
622#if MESH_DEBUG 630#if MESH_DEBUG_DHT
623 &mesh_debug, "DHT_put for id completed"); 631 &mesh_debug, "DHT_put for id completed");
624#else 632#else
625 NULL, /* Continuation */ 633 NULL, /* Continuation */