[json-glib] reader: Make json_reader_get_value return a value for the null type. This matches the json_reader_is
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [json-glib] reader: Make json_reader_get_value return a value for the null type. This matches the json_reader_is
- Date: Sat, 18 Mar 2017 18:55:51 +0000 (UTC)
commit 21b9dcd423d3def6ba871de8d9e4e6916f2954dc
Author: Robert Ancell <robert ancell canonical com>
Date: Tue Nov 24 22:03:32 2015 +1300
reader: Make json_reader_get_value return a value for the null type. This matches the
json_reader_is_value check.
https://bugzilla.gnome.org/show_bug.cgi?id=758580
json-glib/json-reader.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/json-glib/json-reader.c b/json-glib/json-reader.c
index a4c5838..6117ced 100644
--- a/json-glib/json-reader.c
+++ b/json-glib/json-reader.c
@@ -843,7 +843,7 @@ json_reader_get_value (JsonReader *reader)
node = reader->priv->current_node;
- if (!JSON_NODE_HOLDS_VALUE (node))
+ if (!JSON_NODE_HOLDS_VALUE (node) && !JSON_NODE_HOLDS_NULL (node))
{
json_reader_set_error (reader, JSON_READER_ERROR_NO_VALUE,
_("The current position holds a ā%sā and not a value"),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]