From 9e25fdf1ea3e4f52a72bfefc053a701989b7af24 Mon Sep 17 00:00:00 2001
From: Prerna Garg <prerna.g...@live.com>
Date: Wed, 12 Apr 2017 01:29:40 +0530
Subject: [PATCH 2/2] Changed malloc and free to g_malloc and g_free in
 util/compatfd.c

Signed-off-by: Prerna Garg <prerna.g...@live.com>
---
 util/compatfd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/util/compatfd.c b/util/compatfd.c
index 980bd33..7bf1344 100644
--- a/util/compatfd.c
+++ b/util/compatfd.c
@@ -71,14 +71,14 @@ static int qemu_signalfd_compat(const sigset_t *mask)
     QemuThread thread;
     int fds[2];
 
-    info = malloc(sizeof(*info));
+    info = g_malloc(sizeof(*info));
     if (info == NULL) {
         errno = ENOMEM;
         return -1;
     }
 
     if (pipe(fds) == -1) {
-        free(info);
+        g_free(info);
         return -1;
     }
 
-- 
2.7.4

Reply via email to