qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-trivial] [PATCH 12/88] backends/hostmem: use g_new() family of fun


From: Philippe Mathieu-Daudé
Subject: [Qemu-trivial] [PATCH 12/88] backends/hostmem: use g_new() family of functions
Date: Fri, 6 Oct 2017 20:49:07 -0300

Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
---
 backends/hostmem.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/backends/hostmem.c b/backends/hostmem.c
index ee2c2d5bfd..6a12f920c2 100644
--- a/backends/hostmem.c
+++ b/backends/hostmem.c
@@ -78,7 +78,7 @@ host_memory_backend_get_host_nodes(Object *obj, Visitor *v, 
const char *name,
         return;
     }
 
-    *node = g_malloc0(sizeof(**node));
+    *node = g_new0(uint16List, 1);
     (*node)->value = value;
     node = &(*node)->next;
 
@@ -88,7 +88,7 @@ host_memory_backend_get_host_nodes(Object *obj, Visitor *v, 
const char *name,
             break;
         }
 
-        *node = g_malloc0(sizeof(**node));
+        *node = g_new0(uint16List, 1);
         (*node)->value = value;
         node = &(*node)->next;
     } while (true);
-- 
2.14.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]