mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 13:33:09 +07:00
Custom conditions include :ID; 'name:foo :bar' => svc/foo/bar
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
+1
-1
@@ -83,7 +83,7 @@ char *mkcond(svc_t *svc, char *buf, size_t len)
|
||||
|
||||
/* Custom name:foo declaration found => svc/foo instead of /svc/bin/path/pidfile-.pid */
|
||||
if (strcmp(nm, svc->name)) {
|
||||
snprintf(buf, len, "svc/%s", svc->name);
|
||||
snprintf(buf, len, "svc/%s/%s", svc->name, svc->id);
|
||||
_d("Composed condition from svc->name %s => %s", svc->name, buf);
|
||||
} else {
|
||||
snprintf(buf, len, "svc%s%s%s", path[0] != 0 && path[0] != '/' ? "/" : "", path, ptr);
|
||||
|
||||
Reference in New Issue
Block a user