]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Don't set the broadcast flag anymore as all BPF and Linux sockets should be
authorRoy Marples <roy@marples.name>
Mon, 11 Dec 2006 13:16:28 +0000 (13:16 +0000)
committerRoy Marples <roy@marples.name>
Mon, 11 Dec 2006 13:16:28 +0000 (13:16 +0000)
able to unicast correctly.

ChangeLog
Makefile
dhcp.c

index 8ee7ecee0af3edc70e3bf8f42103080562e8e06f..cca60bc38034579eab35a62179320a49280f35da 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+dhcpcd-3.0.6
+Don't set the broadcast flag anymore as all BPF and Linux sockets should be
+able to unicast correctly.
+
 dhcpcd-3.0.5
 Fix yp.conf creation.
 
index 069e9ac0b6ba31e82833cd01dd50c635270bf3ba..0a2cc47f2f008c50b6b403b4ee53a547252b9ecb 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,6 @@
-# Should work for both GNU make and BSD mke
+# Should work for both GNU make and BSD make
 
-VERSION = 3.0.5
+VERSION = 3.0.6
 
 INSTALL ?= install
 CFLAGS ?= -Wall -O2 -pedantic -std=gnu99
diff --git a/dhcp.c b/dhcp.c
index b7bab52a06c69d9faa3ae9699107bcf8cc34decc..87aa93b1d3b09d83387265db5f9598f3a783bb01 100644 (file)
--- a/dhcp.c
+++ b/dhcp.c
@@ -91,15 +91,6 @@ size_t send_message (interface_t *iface, dhcp_t *dhcp,
   memcpy (&message.hwaddr, &iface->ethernet_address, ETHER_ADDR_LEN);
   message.cookie = htonl (MAGIC_COOKIE);
 
-  /* This logic should be improved so that we don't need to set the 0
-     flag as it's done in the above memset statement */
-  if (type == DHCP_REQUEST
-      && dhcp->address.s_addr == iface->previous_address.s_addr
-      && iface->previous_address.s_addr != 0)
-    message.flags = 0;
-  else
-    message.flags = htons (BROADCAST_FLAG);
-
   if (iface->previous_address.s_addr != 0
       && (type == DHCP_INFORM || type == DHCP_RELEASE
          || (type == DHCP_REQUEST