gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r19610 - gnunet/src/mesh


From: gnunet
Subject: [GNUnet-SVN] r19610 - gnunet/src/mesh
Date: Wed, 1 Feb 2012 18:38:19 +0100

Author: bartpolot
Date: 2012-02-01 18:38:19 +0100 (Wed, 01 Feb 2012)
New Revision: 19610

Modified:
   gnunet/src/mesh/gnunet-service-mesh.c
   gnunet/src/mesh/mesh_api.c
Log:
- Define new debug statements

Modified: gnunet/src/mesh/gnunet-service-mesh.c
===================================================================
--- gnunet/src/mesh/gnunet-service-mesh.c       2012-02-01 17:37:37 UTC (rev 
19609)
+++ gnunet/src/mesh/gnunet-service-mesh.c       2012-02-01 17:38:19 UTC (rev 
19610)
@@ -73,7 +73,17 @@
 
 #define MESH_DEBUG_DHT GNUNET_NO
 
+#if MESH_DEBUG
+#define DEBUG(...) GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, __VA_ARGS__)
+#else
+#define DEBUG(...)
+#endif
 
+#if MESH_DEBUG_DHT
+#define DEBUG_DHT(...) GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, __VA_ARGS__)
+#else
+#define DEBUG_DHT(...)
+#endif
 
 
/******************************************************************************/
 /************************      DATA STRUCTURES     
****************************/
@@ -477,7 +487,7 @@
   {
     return;
   }
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "MESH: %s\n", s);
+  DEBUG ("MESH: %s\n", s);
 }
 #endif
 

Modified: gnunet/src/mesh/mesh_api.c
===================================================================
--- gnunet/src/mesh/mesh_api.c  2012-02-01 17:37:37 UTC (rev 19609)
+++ gnunet/src/mesh/mesh_api.c  2012-02-01 17:38:19 UTC (rev 19610)
@@ -47,7 +47,11 @@
 
 #define MESH_API_DEBUG GNUNET_YES
 
+#if MESH_API_DEBUG
 #define LOG(kind,...) GNUNET_log_from (kind, "mesh-api",__VA_ARGS__)
+#else
+#define LOG(kind,...)
+#endif
 
 
/******************************************************************************/
 /************************      DATA STRUCTURES     
****************************/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]