diff options
author | Christian Grothoff <grothoff@gnunet.org> | 2023-08-12 09:26:42 +0200 |
---|---|---|
committer | Christian Grothoff <grothoff@gnunet.org> | 2023-08-12 09:26:42 +0200 |
commit | a72ba44a33bd863a4e92f4253dc7602014c1d5f8 (patch) | |
tree | 9d119f66e12e9053f2339ecb89c354a08d918ba1 /src/json | |
parent | 0208fc5ef550a94c7a4a09fde0242b40996f804f (diff) |
-fix -l option
Diffstat (limited to 'src/json')
-rw-r--r-- | src/json/json_helper.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/json/json_helper.c b/src/json/json_helper.c index 95c1be5fc..2a161eaf0 100644 --- a/src/json/json_helper.c +++ b/src/json/json_helper.c @@ -1261,8 +1261,11 @@ i18n_cleaner (void *cls, struct I18nContext *ctx = cls; (void) spec; - GNUNET_free (ctx->lp); - GNUNET_free (ctx); + if (NULL != ctx) + { + GNUNET_free (ctx->lp); + GNUNET_free (ctx); + } } @@ -1282,8 +1285,9 @@ TALER_JSON_spec_i18n_string (const char *name, .size_ptr = NULL }; - ctx->lp = (NULL != language_pattern) ? GNUNET_strdup (language_pattern) : - NULL; + ctx->lp = (NULL != language_pattern) + ? GNUNET_strdup (language_pattern) + : NULL; ctx->field = name; *strptr = NULL; return ret; |