aboutsummaryrefslogtreecommitdiff
path: root/tests/q35-test.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2017-01-27 13:06:58 +0400
committerMarc-André Lureau <marcandre.lureau@redhat.com>2017-03-01 11:50:33 +0400
commitfb6faea888c1e54059aed7f87be93de623b346ee (patch)
tree82b4ed0a5165338858806970405dc9b661df1501 /tests/q35-test.c
parentf3f8e81150953f2829d39eef9f91f02a38a0c340 (diff)
tests: fix q35-test leaks
Spotted by ASAN. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'tests/q35-test.c')
-rw-r--r--tests/q35-test.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/q35-test.c b/tests/q35-test.c
index 763fe3d6ae..cc58f3ecf4 100644
--- a/tests/q35-test.c
+++ b/tests/q35-test.c
@@ -71,6 +71,9 @@ static void test_smram_lock(void)
g_assert(smram_test_bit(pcidev, MCH_HOST_BRIDGE_SMRAM_D_OPEN) == false);
smram_set_bit(pcidev, MCH_HOST_BRIDGE_SMRAM_D_OPEN, true);
g_assert(smram_test_bit(pcidev, MCH_HOST_BRIDGE_SMRAM_D_OPEN) == true);
+
+ g_free(pcidev);
+ qpci_free_pc(pcibus);
}
int main(int argc, char **argv)