aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2015-11-24 18:06:27 +0100
committerMarkus Armbruster <armbru@redhat.com>2015-11-25 10:24:04 +0100
commit1613094766602bdb8cae337ceecd8ab68f956197 (patch)
treec2bd468441054dbddf9be99cd49f859268e35866 /tests
parenta9282c25a5e2e860dfba5eca6d08fb2e42ee4f1a (diff)
downloadqemu-1613094766602bdb8cae337ceecd8ab68f956197.zip
qemu-1613094766602bdb8cae337ceecd8ab68f956197.tar.gz
qemu-1613094766602bdb8cae337ceecd8ab68f956197.tar.bz2
tests/ivshmem-test: Supply missing initializer in get_device()
If the device isn't found, the assertion uses dev without initialization. Fix that. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <1448384789-14830-4-git-send-email-armbru@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/ivshmem-test.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/ivshmem-test.c b/tests/ivshmem-test.c
index f1793ba..8f1a849 100644
--- a/tests/ivshmem-test.c
+++ b/tests/ivshmem-test.c
@@ -40,6 +40,7 @@ static QPCIDevice *get_device(void)
QPCIBus *pcibus;
pcibus = qpci_init_pc();
+ dev = NULL;
qpci_device_foreach(pcibus, 0x1af4, 0x1110, save_fn, &dev);
g_assert(dev != NULL);