only log with json_dumpf() if explicitly compiled via DEBUG #define
This commit is contained in:
parent
4b9fb610d8
commit
95333b4223
@ -52,6 +52,10 @@
|
|||||||
*/
|
*/
|
||||||
#define EXCHANGE_SERIALIZATION_FORMAT_VERSION 0
|
#define EXCHANGE_SERIALIZATION_FORMAT_VERSION 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set to 1 for extra debug logging.
|
||||||
|
*/
|
||||||
|
#define DEBUG 0
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Log error related to CURL operations.
|
* Log error related to CURL operations.
|
||||||
@ -524,9 +528,11 @@ parse_json_auditor (struct TALER_EXCHANGE_AuditorInformation *auditor,
|
|||||||
NULL, NULL))
|
NULL, NULL))
|
||||||
{
|
{
|
||||||
GNUNET_break_op (0);
|
GNUNET_break_op (0);
|
||||||
|
#if DEBUG
|
||||||
json_dumpf (auditor_obj,
|
json_dumpf (auditor_obj,
|
||||||
stderr,
|
stderr,
|
||||||
JSON_INDENT (2));
|
JSON_INDENT (2));
|
||||||
|
#endif
|
||||||
return GNUNET_SYSERR;
|
return GNUNET_SYSERR;
|
||||||
}
|
}
|
||||||
auditor->auditor_url = GNUNET_strdup (auditor_url);
|
auditor->auditor_url = GNUNET_strdup (auditor_url);
|
||||||
@ -790,9 +796,11 @@ decode_keys_json (const json_t *resp_obj,
|
|||||||
GNUNET_break_op (0);
|
GNUNET_break_op (0);
|
||||||
return GNUNET_SYSERR;
|
return GNUNET_SYSERR;
|
||||||
}
|
}
|
||||||
|
#if DEBUG
|
||||||
json_dumpf (resp_obj,
|
json_dumpf (resp_obj,
|
||||||
stderr,
|
stderr,
|
||||||
JSON_INDENT (2));
|
JSON_INDENT (2));
|
||||||
|
#endif
|
||||||
/* check the version */
|
/* check the version */
|
||||||
{
|
{
|
||||||
const char *ver;
|
const char *ver;
|
||||||
|
@ -28,6 +28,12 @@
|
|||||||
#include "taler_crypto_lib.h"
|
#include "taler_crypto_lib.h"
|
||||||
#include "taler_json_lib.h"
|
#include "taler_json_lib.h"
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set to 1 for extra debug logging.
|
||||||
|
*/
|
||||||
|
#define DEBUG 0
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Handle for a GET /management/keys request.
|
* @brief Handle for a GET /management/keys request.
|
||||||
*/
|
*/
|
||||||
@ -196,9 +202,11 @@ handle_ok (struct TALER_EXCHANGE_ManagementGetKeysHandle *gh,
|
|||||||
NULL, NULL))
|
NULL, NULL))
|
||||||
{
|
{
|
||||||
GNUNET_break_op (0);
|
GNUNET_break_op (0);
|
||||||
|
#if DEBUG
|
||||||
json_dumpf (j,
|
json_dumpf (j,
|
||||||
stderr,
|
stderr,
|
||||||
JSON_INDENT (2));
|
JSON_INDENT (2));
|
||||||
|
#endif
|
||||||
ok = false;
|
ok = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user