diff options
| author | Roy Marples <roy@marples.name> | 2020-10-16 14:36:34 +0100 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2020-10-16 14:36:34 +0100 |
| commit | 3db40d00c4bd5853be00b1b00193e3b3c34adec6 (patch) | |
| tree | 47900cf5d87a2a61704e30826d3be975a3b23890 /src/if.c | |
| parent | 2a5ca0e317b4a1044c4774f8508a279ea1711933 (diff) | |
| download | dhcpcd-3db40d00c4bd5853be00b1b00193e3b3c34adec6.tar.xz | |
BSD: LINK_UNKNOWN is traditionally treated as LINK_UP
Diffstat (limited to 'src/if.c')
| -rw-r--r-- | src/if.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -198,10 +198,8 @@ if_is_link_up(const struct interface *ifp) { return ifp->flags & IFF_UP && - (ifp->carrier == LINK_UP || - (ifp->carrier == LINK_UNKNOWN && - !(ifp->options == NULL || - ifp->options->options & DHCPCD_LINK))); + (ifp->carrier != LINK_DOWN || + (ifp->options != NULL && !(ifp->options->options & DHCPCD_LINK))); } int |
