basic/proc-cmdline: allow parsing of cmdline from a string
Comes with tests. Also add direct test for $SYSTEMD_PROC_CMDLINE. In test-proc-cmdline, "true" was masquerading as PROC_CMDLINE_STRIP_RD_PREFIX, fix that. Also, reorder functions to match call order.
This commit is contained in:
@@ -14,6 +14,7 @@ typedef int (*proc_cmdline_parse_t)(const char *key, const char *value, void *da
|
||||
|
||||
int proc_cmdline(char **ret);
|
||||
|
||||
int proc_cmdline_parse_given(const char *line, proc_cmdline_parse_t parse_item, void *data, unsigned flags);
|
||||
int proc_cmdline_parse(const proc_cmdline_parse_t parse, void *userdata, unsigned flags);
|
||||
|
||||
int proc_cmdline_get_key(const char *parameter, unsigned flags, char **value);
|
||||
|
||||
Reference in New Issue
Block a user