X-Git-Url: https://tinc-vpn.org/git/browse?p=tinc;a=blobdiff_plain;f=src%2Ftincd.c;h=148e13e444ef2c7ef8188e04baa3e1a189504a55;hp=443301e083f178a501926dd0d383315463c2409b;hb=89f4574e0b1553c8e5dcbfc275e829a759b697f6;hpb=cc6aee784659bfbd21eb8d414e00a8f1a801cac4 diff --git a/src/tincd.c b/src/tincd.c index 443301e0..148e13e4 100644 --- a/src/tincd.c +++ b/src/tincd.c @@ -539,6 +539,12 @@ int main(int argc, char **argv) { g_argv = argv; + if(getenv("LISTEN_PID") && atoi(getenv("LISTEN_PID")) == getpid()) + do_detach = false; +#ifdef HAVE_UNSETENV + unsetenv("LISTEN_PID"); +#endif + init_configuration(&config_tree); /* Slllluuuuuuurrrrp! */