Skip to content

Commit

Permalink
Fix wrongly handled absence of candidates
Browse files Browse the repository at this point in the history
Accoding to json-glib documentation: https://developer.gnome.org/json-glib/stable/JsonReader.html

"If reader is not currently on an object, or if the member_name is not defined in the object, the JsonReader will be put in an error state until json_reader_end_member() is called. This means that if used conditionally, json_reader_end_member() must be called on both code paths."

Closes #665.
  • Loading branch information
danips authored and superdump committed Jan 5, 2017
1 parent 3a22666 commit 4d89381
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/test_client.c
Expand Up @@ -583,8 +583,8 @@ static void handle_offer(JsonReader *reader)
g_object_unref(remote_candidate);
json_reader_end_element(reader);
}
json_reader_end_member(reader); /* candidates */
}
json_reader_end_member(reader); /* candidates */
json_reader_end_member(reader); /* ice */

json_reader_end_element(reader);
Expand Down

0 comments on commit 4d89381

Please sign in to comment.