core: don't complain about systemd.journald.xxx kernel command line arguments in PID 1

https://bugzilla.redhat.com/show_bug.cgi?id=880025
This commit is contained in:
Lennart Poettering 2013-03-07 18:39:06 +01:00
parent 614e5fbb8b
commit dd7c30c36a
1 changed files with 30 additions and 19 deletions

View File

@ -375,6 +375,16 @@ static int parse_proc_cmdline_word(const char *word) {
} else if (startswith(word, "systemd.") ||
(in_initrd() && startswith(word, "rd.systemd."))) {
const char *c;
/* Ignore systemd.journald.xyz and friends */
c = word;
if (startswith(c, "rd."))
c += 3;
if (startswith(c, "systemd."))
c += 8;
if (c[strcspn(c, ".=")] != '.') {
log_warning("Unknown kernel switch %s. Ignoring.", word);
log_info("Supported kernel switches:\n"
@ -395,6 +405,7 @@ static int parse_proc_cmdline_word(const char *word) {
"systemd.default_standard_error=null|tty|syslog|syslog+console|kmsg|kmsg+console|journal|journal+console\n"
" Set default log error output for services\n"
"systemd.setenv=ASSIGNMENT Set an environment variable for all spawned processes\n");
}
} else if (streq(word, "quiet"))
arg_show_status = false;