]> git.proxmox.com Git - mirror_qemu.git/commit - qobject/json-parser.c
qapi: Make more of qobject_to()
authorMax Reitz <mreitz@redhat.com>
Sat, 10 Mar 2018 22:14:36 +0000 (16:14 -0600)
committerEric Blake <eblake@redhat.com>
Mon, 19 Mar 2018 19:58:36 +0000 (14:58 -0500)
commit532fb532847365f61a9c6e1291b6588a43bc1cc4
tree46d7355bfca3e0ab48784eec191e2d81f383fa68
parentcb51b976babf7ee16dc5eda4f2189d65b8b700a3
qapi: Make more of qobject_to()

This patch reworks some places which use either qobject_type() checks
plus qobject_to(), where the latter alone is sufficient, or NULL checks
plus qobject_type() checks where we can simply do a qobject_to() != NULL
check.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Alberto Garcia <berto@igalia.com>
Message-Id: <20180224154033.29559-6-mreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
[eblake: rebase to qobject_to() parameter ordering]
Signed-off-by: Eric Blake <eblake@redhat.com>
qapi/qobject-input-visitor.c
qobject/json-parser.c
qobject/qdict.c