X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=socket.c;h=402eeaf628b04fa3336f1fe0c98417789a941c3e;hb=afb757b1a8a416b3c692728330a266b3915eef41;hp=cb065b75bfeca5af7f7d31b2b34e6d403f9846f1;hpb=cabab516b38fbb2146bb62980b6770b1f70403fa;p=elogind.git diff --git a/socket.c b/socket.c index cb065b75b..402eeaf62 100644 --- a/socket.c +++ b/socket.c @@ -578,6 +578,7 @@ static int socket_spawn(Socket *s, ExecCommand *c, pid_t *_pid) { argv, &s->exec_context, NULL, 0, + s->meta.manager->environment, true, true, UNIT(s)->meta.manager->confirm_spawn, @@ -667,7 +668,7 @@ static void socket_enter_signal(Socket *s, SocketState state, bool success) { } } - if (sent) { + if (sent && s->control_pid > 0) { if ((r = unit_watch_timer(UNIT(s), s->timeout_usec, &s->timer_watch)) < 0) goto fail; @@ -1110,7 +1111,6 @@ static void socket_fd_event(Unit *u, int fd, uint32_t events, Watch *w) { } } - log_debug("cfd=%i", cfd); socket_enter_running(s, cfd); return;