0a122b
From ca20b922adfc76c1aff60e86ae731295cf82f884 Mon Sep 17 00:00:00 2001
0a122b
Message-Id: <ca20b922adfc76c1aff60e86ae731295cf82f884.1387382496.git.minovotn@redhat.com>
0a122b
In-Reply-To: <c5386144fbf09f628148101bc674e2421cdd16e3.1387382496.git.minovotn@redhat.com>
0a122b
References: <c5386144fbf09f628148101bc674e2421cdd16e3.1387382496.git.minovotn@redhat.com>
0a122b
From: Nigel Croxon <ncroxon@redhat.com>
0a122b
Date: Thu, 14 Nov 2013 22:53:02 +0100
0a122b
Subject: [PATCH 26/46] rdma: memory leak RDMAContext::host
0a122b
0a122b
RH-Author: Nigel Croxon <ncroxon@redhat.com>
0a122b
Message-id: <1384469598-13137-27-git-send-email-ncroxon@redhat.com>
0a122b
Patchwork-id: 55704
0a122b
O-Subject: [RHEL7.0 PATCH 26/42] rdma: memory leak RDMAContext::host
0a122b
Bugzilla: 1011720
0a122b
RH-Acked-by: Orit Wasserman <owasserm@redhat.com>
0a122b
RH-Acked-by: Amit Shah <amit.shah@redhat.com>
0a122b
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
0a122b
0a122b
Bugzilla: 1011720
0a122b
https://bugzilla.redhat.com/show_bug.cgi?id=1011720
0a122b
0a122b
>From commit ID:
0a122b
commit e1d0fb378ae3bb4272124a12e3fe1a02c4745eb1
0a122b
Author: Isaku Yamahata <yamahata@private.email.ne.jp>
0a122b
Date:   Sat Aug 3 22:54:54 2013 -0400
0a122b
0a122b
    rdma: memory leak RDMAContext::host
0a122b
0a122b
    It is allocated by g_strdup(), so needs to be freed.
0a122b
0a122b
    Reviewed-by: Michael R. Hines <mrhines@us.ibm.com>
0a122b
    Signed-off-by: Isaku Yamahata <yamahata@private.email.ne.jp>
0a122b
    Signed-off-by: Michael R. Hines <mrhines@us.ibm.com>
0a122b
    Message-id: 1375584894-9917-8-git-send-email-mrhines@linux.vnet.ibm.com
0a122b
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
0a122b
---
0a122b
 migration-rdma.c |    2 ++
0a122b
 1 files changed, 2 insertions(+), 0 deletions(-)
0a122b
0a122b
Signed-off-by: Michal Novotny <minovotn@redhat.com>
0a122b
---
0a122b
 migration-rdma.c | 2 ++
0a122b
 1 file changed, 2 insertions(+)
0a122b
0a122b
diff --git a/migration-rdma.c b/migration-rdma.c
0a122b
index 6afe98c..ff0a823 100644
0a122b
--- a/migration-rdma.c
0a122b
+++ b/migration-rdma.c
0a122b
@@ -2097,6 +2097,8 @@ static void qemu_rdma_cleanup(RDMAContext *rdma)
0a122b
         rdma_destroy_event_channel(rdma->channel);
0a122b
         rdma->channel = NULL;
0a122b
     }
0a122b
+    g_free(rdma->host);
0a122b
+    rdma->host = NULL;
0a122b
 }
0a122b
 
0a122b
 
0a122b
-- 
0a122b
1.7.11.7
0a122b