mirror of
https://github.com/troglobit/finit.git
synced 2026-10-31 13:00:32 +00:00
Set default user/group for services that don't specify any
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
548acf27cf
commit
6dec4c9ca0
3 files changed
+41
No files matched your search
@@ -1145,6 +1145,9 @@ int service_register(int type, char *cfg, struct rlimit rlimit[], char *file)
|
||||
strlcpy(svc->group, ptr, sizeof(svc->group));
|
||||
}
|
||||
strlcpy(svc->username, username, sizeof(svc->username));
|
||||
} else {
|
||||
getcuser(svc->username, sizeof(svc->username));
|
||||
getcgroup(svc->group, sizeof(svc->group));
|
||||
}
|
||||
|
||||
parse_cmdline_args(svc, cmd);
|
||||
|
||||
Reference in new issue
Block a user