projects
/
platform
/
upstream
/
dbus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2313832
)
fix socket descriptor leak in _dbus_connect_tcp_socket_with_nonce
author
Romain Pokrzywka
<romain@kdab.com>
Sun, 8 Aug 2010 21:54:35 +0000
(23:54 +0200)
committer
Ralf Habacker
<ralf.habacker@freenet.de>
Mon, 9 Aug 2010 00:55:41 +0000
(
02:55
+0200)
dbus/dbus-sysdeps-win.c
patch
|
blob
|
history
diff --git
a/dbus/dbus-sysdeps-win.c
b/dbus/dbus-sysdeps-win.c
index
aad342c
..
7f9d559
100644
(file)
--- a/
dbus/dbus-sysdeps-win.c
+++ b/
dbus/dbus-sysdeps-win.c
@@
-1294,6
+1294,7
@@
_dbus_connect_tcp_socket_with_nonce (const char *host,
dbus_set_error (error,
_dbus_error_from_errno (errno),
"Unknown address family %s", family);
+ closesocket (fd);
return -1;
}
hints.ai_protocol = IPPROTO_TCP;
@@
-1314,6
+1315,9
@@
_dbus_connect_tcp_socket_with_nonce (const char *host,
return -1;
}
+ closesocket (fd);
+ fd = -1;
+
tmp = ai;
while (tmp)
{