diff options
author | Stefan Weil <sw@weilnetz.de> | 2012-09-01 09:40:26 +0200 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@gmail.com> | 2012-09-23 07:11:28 +0100 |
commit | 39b384591fda27d6e1213cea0b11b1ebe0ed4b74 (patch) | |
tree | 54e60954f1276ddc71dca9b771f6cbce79c3a0b2 /qemu-sockets.c | |
parent | b548828862d3bf7214b7ef9cb361356b153b89c9 (diff) |
qemu-sockets: Fix potential memory leak
The old code leaks variable 'peer'.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com>
Diffstat (limited to 'qemu-sockets.c')
-rw-r--r-- | qemu-sockets.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qemu-sockets.c b/qemu-sockets.c index 361d890da3..037775b86b 100644 --- a/qemu-sockets.c +++ b/qemu-sockets.c @@ -353,7 +353,7 @@ int inet_dgram_opts(QemuOpts *opts) if (0 != (rc = getaddrinfo(addr, port, &ai, &local))) { fprintf(stderr,"getaddrinfo(%s,%s): %s\n", addr, port, gai_strerror(rc)); - return -1; + goto err; } /* create socket */ |