diff mbox series

[09/88] Bootdevice: use g_new() family of functions

Message ID 20171006235023.11952-10-f4bug@amsat.org
State New
Headers show
Series use g_new() family of functions | expand

Commit Message

Philippe Mathieu-Daudé Oct. 6, 2017, 11:49 p.m. UTC
From: Marc-André Lureau <marcandre.lureau@redhat.com>

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
 bootdevice.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/bootdevice.c b/bootdevice.c
index 1141009114..a2936503da 100644
--- a/bootdevice.c
+++ b/bootdevice.c
@@ -165,7 +165,7 @@  void add_boot_device_path(int32_t bootindex, DeviceState *dev,
 
     del_boot_device_path(dev, suffix);
 
-    node = g_malloc0(sizeof(FWBootEntry));
+    node = g_new0(FWBootEntry, 1);
     node->bootindex = bootindex;
     node->suffix = g_strdup(suffix);
     node->dev = dev;