]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Don't start arping if there is no configuration for it.
authorRoy Marples <roy@marples.name>
Tue, 13 Dec 2016 20:39:30 +0000 (20:39 +0000)
committerRoy Marples <roy@marples.name>
Tue, 13 Dec 2016 20:39:30 +0000 (20:39 +0000)
dhcp.c

diff --git a/dhcp.c b/dhcp.c
index 02950f81a9d0a6a26f4fbf8f59d746265c798bee..9e7e5a078afda76b929858785c453c8579d5f406 100644 (file)
--- a/dhcp.c
+++ b/dhcp.c
@@ -2024,7 +2024,7 @@ dhcp_arp_probed(struct arp_state *astate)
        state = D_STATE(ifp);
        ifo = ifp->options;
 #ifdef ARPING
-       if (state->arping_index < ifo->arping_len) {
+       if (ifo->arping_len && state->arping_index < ifo->arping_len) {
                /* We didn't find a profile for this
                 * address or hwaddr, so move to the next
                 * arping profile */
@@ -3529,7 +3529,7 @@ dhcp_start1(void *arg)
        state->offer_len = 0;
 
 #ifdef ARPING
-       if (state->arping_index < ifo->arping_len) {
+       if (ifo->arping_len && state->arping_index < ifo->arping_len) {
                struct arp_state *astate;
 
                astate = arp_new(ifp, NULL);