]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Fix waiting on non interface ip, [2095791c47].
authorRoy Marples <roy@marples.name>
Thu, 14 May 2015 09:20:26 +0000 (09:20 +0000)
committerRoy Marples <roy@marples.name>
Thu, 14 May 2015 09:20:26 +0000 (09:20 +0000)
dhcpcd.c

index 5f21a920db1cf4865935911b154c585fb63cc7bb..27c5ac9191e5292af609e9deaefd0119987a278e 100644 (file)
--- a/dhcpcd.c
+++ b/dhcpcd.c
@@ -234,8 +234,8 @@ dhcpcd_ipwaited(struct dhcpcd_ctx *ctx)
        struct interface *ifp;
 
        TAILQ_FOREACH(ifp, ctx->ifaces, next) {
-               if (!dhcpcd_ifipwaited(ifp, ifp->options->options)) {
-                       if (ifp->options->options & DHCPCD_WAITOPTS) {
+               if (ifp->options->options & DHCPCD_WAITOPTS) {
+                       if (!dhcpcd_ifipwaited(ifp, ifp->options->options)) {
                                logger(ctx, LOG_DEBUG,
                                    "%s: waiting for an ip address",
                                    ifp->name);
@@ -248,7 +248,7 @@ dhcpcd_ipwaited(struct dhcpcd_ctx *ctx)
                return 1;
 
        TAILQ_FOREACH(ifp, ctx->ifaces, next) {
-               if (dhcpcd_ifipwaited(ifp, ifp->options->options))
+               if (dhcpcd_ifipwaited(ifp, ctx->options))
                        return 1;
        }