summaryrefslogtreecommitdiff
path: root/gdata/services
diff options
context:
space:
mode:
authorPhilip Withnall <philip@tecnocode.co.uk>2015-05-03 12:09:22 +0100
committerPhilip Withnall <philip@tecnocode.co.uk>2015-05-03 12:09:22 +0100
commite98aabd114aa5d86d41b0da50c720fda58cd3b1e (patch)
tree032233b3a6609144a74ac657a9e889c8b112485f /gdata/services
parentf6f4e3e5eb75d1f17eb1fa9cc8aa3c9b31bb38f1 (diff)
downloadlibgdata-e98aabd114aa5d86d41b0da50c720fda58cd3b1e.tar.gz
documents: Assert that parsing a known JSON string member succeeds
gdata_parser_string_from_json_member() should return TRUE iff it matched the given member (even if parsing fails). Since the member name comes from a loop over the existing members, this should always succeed. Spotted by Coverity. CID: #109873
Diffstat (limited to 'gdata/services')
-rw-r--r--gdata/services/documents/gdata-documents-document.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdata/services/documents/gdata-documents-document.c b/gdata/services/documents/gdata-documents-document.c
index 625a7e8f..46d0a295 100644
--- a/gdata/services/documents/gdata-documents-document.c
+++ b/gdata/services/documents/gdata-documents-document.c
@@ -295,7 +295,7 @@ parse_json (GDataParsable *parsable, JsonReader *reader, gpointer user_data, GEr
format = json_reader_get_member_name (reader);
- gdata_parser_string_from_json_member (reader, format, P_REQUIRED | P_NON_EMPTY, &uri, &success, NULL);
+ g_assert (gdata_parser_string_from_json_member (reader, format, P_REQUIRED | P_NON_EMPTY, &uri, &success, NULL));
if (success) {
g_hash_table_insert (priv->export_links, g_strdup (format), uri);
uri = NULL;