aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/json/json_helper.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/json/json_helper.c b/src/json/json_helper.c
index b39500f75..e8c6d4cbc 100644
--- a/src/json/json_helper.c
+++ b/src/json/json_helper.c
@@ -487,7 +487,8 @@ TALER_JSON_spec_i18n_string (const char *name,
.size_ptr = NULL
};
- ctx->lp = GNUNET_strdup (language_pattern);
+ ctx->lp = (NULL != language_pattern) ? GNUNET_strdup (language_pattern) :
+ NULL;
ctx->field = name;
*strptr = NULL;
return ret;