mirror of
https://github.com/troglobit/finit.git
synced 2026-10-13 10:14:47 +00:00
Support reading --debug et al from process command line
Up until now Finit has only read /proc/cmdline to determine debug level, single user mode, etc. This patch is one in a series to make enable it to run also in containers. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
+6
-6
@@ -292,6 +292,12 @@ int main(int argc, char *argv[])
|
||||
if (getpid() != 1)
|
||||
return client(argc, argv);
|
||||
|
||||
/*
|
||||
* Parse kernel command line (debug, rescue, splash, etc.)
|
||||
* Also calls log_init() to set correct log level
|
||||
*/
|
||||
conf_parse_cmdline(argc, argv);
|
||||
|
||||
/*
|
||||
* Hide command line arguments from ps (in particular for
|
||||
* forked children that don't execv()). This is an ugly
|
||||
@@ -320,12 +326,6 @@ int main(int argc, char *argv[])
|
||||
chdir("/");
|
||||
umask(0);
|
||||
|
||||
/*
|
||||
* Parse kernel command line (debug, rescue, splash, etc.)
|
||||
* Also calls log_init() to set correct log level
|
||||
*/
|
||||
conf_parse_cmdline();
|
||||
|
||||
/* Set up canvas */
|
||||
if (!rescue && !log_is_debug())
|
||||
screen_init();
|
||||
|
||||
Reference in New Issue
Block a user