diff options
| author | Roy Marples <roy@marples.name> | 2015-02-03 09:00:36 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2015-02-03 09:00:36 +0000 |
| commit | 28fba2bb64d538f039e0e1f1dacc212b69ca23e5 (patch) | |
| tree | d7120fe2d72be27202a034e609d507f5d822d285 /dhcpcd.c | |
| parent | 6dff2cb37141ab252ab343ab50083630b384c2e6 (diff) | |
| download | dhcpcd-28fba2bb64d538f039e0e1f1dacc212b69ca23e5.tar.xz | |
Test mode removes the daemonise bit, so check for both when setting the timeout.
Diffstat (limited to 'dhcpcd.c')
| -rw-r--r-- | dhcpcd.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1760,7 +1760,10 @@ main(int argc, char **argv) syslog(LOG_WARNING, "no interfaces have a carrier"); if (dhcpcd_daemonise(&ctx)) goto exit_success; - } else if (t > 0 && ctx.options & DHCPCD_DAEMONISE) { + } else if (t > 0 && + /* Test mode removes the daeomise bit, so check for both */ + ctx.options & (DHCPCD_DAEMONISE | DHCPCD_TEST)) + { eloop_timeout_add_sec(ctx.eloop, t, handle_exit_timeout, &ctx); } |
