From 790bbb9768e6a21920e76989f931db80ca67dc10 Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Fri, 6 Oct 2017 20:49:56 -0300 Subject: tests: use g_new() family of functions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Marc-André Lureau Signed-off-by: Philippe Mathieu-Daudé [PMD: split of some files in other commits of the same series, add libqtest.c] Acked-by: John Snow Reviewed-by: Thomas Huth Signed-off-by: Thomas Huth --- tests/libqos/ahci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/libqos/ahci.c') diff --git a/tests/libqos/ahci.c b/tests/libqos/ahci.c index 1ca7f456b5..13c0749582 100644 --- a/tests/libqos/ahci.c +++ b/tests/libqos/ahci.c @@ -843,7 +843,7 @@ AHCICommand *ahci_command_create(uint8_t command_name) AHCICommand *cmd; g_assert(props); - cmd = g_malloc0(sizeof(AHCICommand)); + cmd = g_new0(AHCICommand, 1); g_assert(!(props->dma && props->pio)); g_assert(!(props->lba28 && props->lba48)); g_assert(!(props->read && props->write)); -- cgit 1.4.1