]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Only check auto-configure in the DISCOVER state.
authorRoy Marples <roy@marples.name>
Fri, 31 Jan 2014 22:28:16 +0000 (22:28 +0000)
committerRoy Marples <roy@marples.name>
Fri, 31 Jan 2014 22:28:16 +0000 (22:28 +0000)
dhcp.c

diff --git a/dhcp.c b/dhcp.c
index bc56a00f5badd1126c8e64448a86adfb98fa699f..b9b6c46374060e3d32a846a0e08feaa48404248c 100644 (file)
--- a/dhcp.c
+++ b/dhcp.c
@@ -2274,7 +2274,9 @@ dhcp_handledhcp(struct interface *iface, struct dhcp_message **dhcpp,
                            iface->name, msg);
                        free(msg);
                }
-               if (get_option_uint8(&tmp, dhcp, DHO_AUTOCONFIGURE) != 0) {
+               if (state->state == DHS_DISCOVER &&
+                   get_option_uint8(&tmp, dhcp, DHO_AUTOCONFIGURE) != 0)
+               {
                        switch (tmp) {
                        case 0:
                                log_dhcp(LOG_WARNING, "IPv4LL disabled from",