diff options
| author | Roy Marples <roy@marples.name> | 2019-01-23 13:50:34 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2019-01-23 13:50:34 +0000 |
| commit | 700fd4e3d3cc65602427816f7446dada757d0538 (patch) | |
| tree | 4a8508b3dfcb81176234792b766fa8d2fd0791d0 /src/if.c | |
| parent | c2ed9a5cf526a854679e09e9ab7a34af548149a0 (diff) | |
| download | dhcpcd-700fd4e3d3cc65602427816f7446dada757d0538.tar.xz | |
IP6ND: Remove #defines for functions when INET6 is disabled
This allows us to optimise the code better and hopefully
become less error prone.
Diffstat (limited to 'src/if.c')
| -rw-r--r-- | src/if.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -88,8 +88,10 @@ if_free(struct interface *ifp) #ifdef DHCP6 dhcp6_free(ifp); #endif +#ifdef INET6 ipv6nd_free(ifp); ipv6_free(ifp); +#endif rt_freeif(ifp); free_options(ifp->ctx, ifp->options); free(ifp); @@ -738,10 +740,12 @@ if_cmp(const struct interface *si, const struct interface *ti) if (!D_STATE_RUNNING(si) && D_STATE_RUNNING(ti)) return 1; #endif +#ifdef INET6 if (RS_STATE_RUNNING(si) && !RS_STATE_RUNNING(ti)) return -1; if (!RS_STATE_RUNNING(si) && RS_STATE_RUNNING(ti)) return 1; +#endif #ifdef DHCP6 if (D6_STATE_RUNNING(si) && !D6_STATE_RUNNING(ti)) return -1; |
