aboutsummaryrefslogtreecommitdiff
path: root/src/json
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-11-19 11:47:52 +0100
committerChristian Grothoff <christian@grothoff.org>2021-11-19 11:47:52 +0100
commit68a4d901347bfa159adfe67e00f149e09800ea22 (patch)
tree9f966c9c1ea7f15954552d0832a7ef1414549735 /src/json
parentbdaaa0f6cb8f99168ed9916064a5e4145426480c (diff)
-misc bugfixes
Diffstat (limited to 'src/json')
-rw-r--r--src/json/json.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/json/json.c b/src/json/json.c
index 62dec7189..479a0ae96 100644
--- a/src/json/json.c
+++ b/src/json/json.c
@@ -558,9 +558,14 @@ seed_forgettable (json_t *f)
GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_NONCE,
&sh,
sizeof (sh));
- json_object_set_new (f,
- key,
- GNUNET_JSON_from_data_auto (&sh));
+ if (0 !=
+ json_object_set_new (f,
+ key,
+ GNUNET_JSON_from_data_auto (&sh)))
+ {
+ GNUNET_break (0);
+ return GNUNET_SYSERR;
+ }
continue;
}
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,