aboutsummaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-05-16 14:17:33 +0200
committerChristian Grothoff <christian@grothoff.org>2023-05-16 14:17:33 +0200
commite371d76cfe1b78cd373046ca6be535157e41793c (patch)
treee882926873b4274e3b96e5429e7444aae6cca114 /src/util
parent30b953ff0f46a49c1a48b6d0b59d18c4cd30e0c6 (diff)
downloadexchange-e371d76cfe1b78cd373046ca6be535157e41793c.tar.xz
add KYC_AML_TRIGGER option (not implemented)
Diffstat (limited to 'src/util')
-rw-r--r--src/util/conversion.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/src/util/conversion.c b/src/util/conversion.c
index 501ca0145..fdeffba40 100644
--- a/src/util/conversion.c
+++ b/src/util/conversion.c
@@ -251,7 +251,7 @@ child_done_cb (void *cls,
long unsigned int exit_code)
{
struct TALER_JSON_ExternalConversion *ec = cls;
- json_t *j;
+ json_t *j = NULL;
json_error_t err;
ec->cwh = NULL;
@@ -269,16 +269,19 @@ child_done_cb (void *cls,
}
GNUNET_OS_process_destroy (ec->helper);
ec->helper = NULL;
- j = json_loadb (ec->read_buf,
- ec->read_pos,
- JSON_REJECT_DUPLICATES,
- &err);
- if (NULL == j)
+ if (0 != ec->read_pos)
{
- GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
- "Failed to parse JSON from helper at %d: %s\n",
- err.position,
- err.text);
+ j = json_loadb (ec->read_buf,
+ ec->read_pos,
+ JSON_REJECT_DUPLICATES,
+ &err);
+ if (NULL == j)
+ {
+ GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+ "Failed to parse JSON from helper at %d: %s\n",
+ err.position,
+ err.text);
+ }
}
ec->cb (ec->cb_cls,
type,