diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2010-11-29 17:44:52 +0100 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2010-11-29 17:44:52 +0100 |
commit | 311f0b1124d761ef510510c5f74c8d02b71ea6d3 (patch) | |
tree | 176f66c4cd0928b63c5bcdce0b858bd63cf314e9 /gdhcp | |
parent | 84af388dd11ae917a40aca48f2156306be4821ec (diff) | |
download | connman-311f0b1124d761ef510510c5f74c8d02b71ea6d3.tar.gz connman-311f0b1124d761ef510510c5f74c8d02b71ea6d3.tar.bz2 connman-311f0b1124d761ef510510c5f74c8d02b71ea6d3.zip |
gdhcp: Initialise socket structure before binding
Diffstat (limited to 'gdhcp')
-rw-r--r-- | gdhcp/client.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gdhcp/client.c b/gdhcp/client.c index 4e687e99..cebe6f4e 100644 --- a/gdhcp/client.c +++ b/gdhcp/client.c @@ -435,6 +435,7 @@ static int dhcp_l2_socket(int ifindex) setsockopt(fd, SOL_SOCKET, SO_ATTACH_FILTER, &filter_prog, sizeof(filter_prog)); + memset(&sock, 0, sizeof(sock)); sock.sll_family = AF_PACKET; sock.sll_protocol = htons(ETH_P_IP); sock.sll_ifindex = ifindex; |