aboutsummaryrefslogtreecommitdiff
path: root/util/qemu-sockets.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2016-07-06 18:42:46 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2016-07-12 18:31:27 +0200
commit73f40c1895980dc705b6b0594ace6580b3f68537 (patch)
tree7614865cc8bf202c67556fb57588639bfc3486d8 /util/qemu-sockets.c
parent1e13c01d2a4eadb9c498caa809a21e3b5672b411 (diff)
downloadqemu-73f40c1895980dc705b6b0594ace6580b3f68537.zip
qemu-73f40c1895980dc705b6b0594ace6580b3f68537.tar.gz
qemu-73f40c1895980dc705b6b0594ace6580b3f68537.tar.bz2
qemu-sockets: use qapi_free_SocketAddress in cleanup
Commit 74b6ce43e3 uses the wrong free API for a SocketAddress, that may leak some linked data. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20160706164246.22116-1-marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'util/qemu-sockets.c')
-rw-r--r--util/qemu-sockets.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/qemu-sockets.c b/util/qemu-sockets.c
index fb83d48..777af49 100644
--- a/util/qemu-sockets.c
+++ b/util/qemu-sockets.c
@@ -1012,7 +1012,7 @@ void socket_listen_cleanup(int fd, Error **errp)
}
}
- g_free(addr);
+ qapi_free_SocketAddress(addr);
}
int socket_dgram(SocketAddress *remote, SocketAddress *local, Error **errp)