projects
/
framework
/
connectivity
/
connman.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3198dcb
)
gdhcp: Possible file descriptor leak
author
Jukka Rissanen
<jukka.rissanen@linux.intel.com>
Fri, 28 Oct 2011 09:28:59 +0000
(12:28 +0300)
committer
Samuel Ortiz
<sameo@linux.intel.com>
Fri, 28 Oct 2011 21:41:30 +0000
(23:41 +0200)
gdhcp/common.c
patch
|
blob
|
history
diff --git
a/gdhcp/common.c
b/gdhcp/common.c
index
43f6735
..
0a2b51b
100644
(file)
--- a/
gdhcp/common.c
+++ b/
gdhcp/common.c
@@
-343,11
+343,11
@@
int dhcp_send_raw_packet(struct dhcp_packet *dhcp_pkt,
*/
n = sendto(fd, &packet, IP_UPD_DHCP_SIZE, 0,
(struct sockaddr *) &dest, sizeof(dest));
+ close(fd);
+
if (n < 0)
return -errno;
- close(fd);
-
return n;
}