summaryrefslogtreecommitdiff
path: root/json-glib/json-array.c
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2015-08-18 14:04:05 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2015-08-18 14:04:05 +0100
commitf7eb50b5b03ee5870e476135bd989cb49d8d44c2 (patch)
treecae2b370bbd968f3556dcfba7df19ad0af764b80 /json-glib/json-array.c
parent4c1485acaa0f7267c87a37477f43808924e5aece (diff)
downloadjson-glib-f7eb50b5b03ee5870e476135bd989cb49d8d44c2.tar.gz
array: Do not create a null node for empty strings
The two are fairly different, and JsonObject does not behave this way. https://bugzilla.gnome.org/show_bug.cgi?id=730803
Diffstat (limited to 'json-glib/json-array.c')
-rw-r--r--json-glib/json-array.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/json-glib/json-array.c b/json-glib/json-array.c
index c747989..ebc6d58 100644
--- a/json-glib/json-array.c
+++ b/json-glib/json-array.c
@@ -551,7 +551,7 @@ json_array_add_string_element (JsonArray *array,
node = json_node_alloc ();
- if (value != NULL && *value != '\0')
+ if (value != NULL)
json_node_init_string (node, value);
else
json_node_init_null (node);