mirror of
https://github.com/troglobit/finit.git
synced 2026-10-29 12:40:44 +00:00
Follow-up to a613ee9, handle reload as well (existing svc)
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
e55fd19091
commit
ecb5949679
1 file changed
+8
-8
+8
-8
@@ -1570,15 +1570,15 @@ int service_register(int type, char *cfg, struct rlimit rlimit[], char *file)
|
||||
} else
|
||||
svc = svc_find(name, id);
|
||||
|
||||
if (!whichp(cmd)) {
|
||||
if (nowarn)
|
||||
return 0;
|
||||
|
||||
warn("%s: skipping %s", file ? file : "static", cmd);
|
||||
return errno;
|
||||
}
|
||||
|
||||
if (!svc) {
|
||||
if (!whichp(cmd)) {
|
||||
if (nowarn)
|
||||
return 0;
|
||||
|
||||
warn("%s: skipping %s", file ? file : "static", cmd);
|
||||
return errno;
|
||||
}
|
||||
|
||||
dbg("Creating new svc for %s name %s id %s type %d", cmd, name, id, type);
|
||||
svc = svc_new(cmd, name, id, type);
|
||||
if (!svc) {
|
||||
|
||||
Reference in new issue
Block a user