mirror of
https://github.com/troglobit/finit.git
synced 2026-11-23 20:11:44 +00:00
conf: pass -- in a block command to the program
A command that takes -- as an argument lost it, and everything after
it, to the description:
service name {
command = "cmd -- arg"
description = "a cmd"
}
ran `cmd` with description `arg`.
The block translator builds a legacy one-liner, appending the
description as "-- text", and service_register() splits that line at
the first "-- ", here the one in the command.
Split the description off only for legacy one-liners. Blocks now hand
it to the new service_register_desc() as an argument.
Fixes #512
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
5 files changed
+69
-30
No files matched your search
@@ -44,6 +44,8 @@ extern const struct svcdir svcdirs[NUM_SVCDIRS];
|
||||
|
||||
int service_set_dir (svc_t *svc, const struct svcdir *sd, const char *name);
|
||||
svc_t *service_register (int type, char *line, struct rlimit rlimit[], char *file);
|
||||
svc_t *service_register_desc (int type, char *line, const char *desc,
|
||||
struct rlimit rlimit[], char *file);
|
||||
void service_unregister (svc_t *svc);
|
||||
|
||||
void service_runtask_clean (void);
|
||||
|
||||
Reference in new issue
Block a user