aboutsummaryrefslogtreecommitdiffstats
path: root/arp.c
diff options
context:
space:
mode:
authorDmitry Shmidt <dimitrysh@google.com>2012-07-23 16:45:46 -0700
committerDmitry Shmidt <dimitrysh@google.com>2012-07-23 16:54:15 -0700
commita3a2260384a906e1674c7498c2f479e9f37bc503 (patch)
tree5e5adc874a930144f847f57a08da862413b63668 /arp.c
parent2af699ea51cca49bd0f19080c9d73170e5bdadbc (diff)
downloadandroid_external_dhcpcd-a3a2260384a906e1674c7498c2f479e9f37bc503.tar.gz
android_external_dhcpcd-a3a2260384a906e1674c7498c2f479e9f37bc503.tar.bz2
android_external_dhcpcd-a3a2260384a906e1674c7498c2f479e9f37bc503.zip
dhcpcd: Update to Version 5.5.6
Change-Id: I98c378688be723a2a602ec17c26bc13f2fd83cc8 Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'arp.c')
-rw-r--r--arp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/arp.c b/arp.c
index 89d63fe..1905508 100644
--- a/arp.c
+++ b/arp.c
@@ -1,6 +1,6 @@
/*
* dhcpcd - DHCP client daemon
- * Copyright (c) 2006-2008 Roy Marples <roy@marples.name>
+ * Copyright (c) 2006-2011 Roy Marples <roy@marples.name>
* All rights reserved
* Redistribution and use in source and binary forms, with or without
@@ -119,7 +119,7 @@ handle_arp_packet(void *arg)
state->fail.s_addr = 0;
for(;;) {
bytes = get_raw_packet(iface, ETHERTYPE_ARP,
- arp_buffer, sizeof(arp_buffer));
+ arp_buffer, sizeof(arp_buffer), NULL);
if (bytes == 0 || bytes == -1)
return;
/* We must have a full ARP header */
@@ -204,6 +204,8 @@ send_arp_announce(void *arg)
struct if_state *state = iface->state;
struct timeval tv;
+ if (state->new == NULL)
+ return;
if (iface->arp_fd == -1) {
open_socket(iface, ETHERTYPE_ARP);
add_event(iface->arp_fd, handle_arp_packet, iface);