mirror of
https://github.com/troglobit/finit.git
synced 2026-11-18 19:30:56 +00:00
initctl: only show log if PID != 0
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
6c874895dc
commit
1c4bad5b73
1 file changed
+2
@@ -164,6 +164,8 @@ static int do_log(svc_t *svc, char *tail)
|
|||||||
if (svc) {
|
if (svc) {
|
||||||
nm = svc_ident(svc, NULL, 0);
|
nm = svc_ident(svc, NULL, 0);
|
||||||
pid = svc->pid;
|
pid = svc->pid;
|
||||||
|
if (!pid)
|
||||||
|
return 0; /* not running */
|
||||||
} else {
|
} else {
|
||||||
nm = "finit";
|
nm = "finit";
|
||||||
pid = 1;
|
pid = 1;
|
||||||
|
|||||||
Reference in new issue
Block a user