aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2017-02-28 22:27:01 +0100
committerMarkus Armbruster <armbru@redhat.com>2017-03-07 16:07:47 +0100
commit02146d27c33675d511dd34134536416c7cd774da (patch)
tree6e44a6b7cb4c4a5c8c986fb371667baf983a6321 /tests
parentaec4b054ea36c53c8b887da99f20010133b84378 (diff)
test-visitor-serialization: Pass &error_abort to qobject_from_json()
qmp_deserialize() calls qobject_from_json() ignoring errors. It passes the result to qobject_input_visitor_new(), which asserts it's not null. Therefore, we can just as well pass &error_abort to qobject_from_json(). Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Kevin Wolf <kwolf@redhat.com> Message-Id: <1488317230-26248-16-git-send-email-armbru@redhat.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/test-visitor-serialization.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/test-visitor-serialization.c b/tests/test-visitor-serialization.c
index 37dff41fbd..4d47ceec7a 100644
--- a/tests/test-visitor-serialization.c
+++ b/tests/test-visitor-serialization.c
@@ -1037,7 +1037,7 @@ static void qmp_deserialize(void **native_out, void *datap,
visit_complete(d->qov, &d->obj);
obj_orig = d->obj;
output_json = qobject_to_json(obj_orig);
- obj = qobject_from_json(qstring_get_str(output_json), NULL);
+ obj = qobject_from_json(qstring_get_str(output_json), &error_abort);
QDECREF(output_json);
d->qiv = qobject_input_visitor_new(obj);