mirror of
https://github.com/RGBCube/serenity
synced 2025-05-18 21:15:09 +00:00
Kernel: Ensure that CommandLine is initialized before choosing PanicMode
If the kernel commandline is not initialized, just halt everything.
This commit is contained in:
parent
0adee378fd
commit
d67c70d043
3 changed files with 8 additions and 0 deletions
|
@ -27,6 +27,11 @@ UNMAP_AFTER_INIT void CommandLine::early_initialize(const char* cmd_line)
|
|||
s_cmd_line[length] = '\0';
|
||||
}
|
||||
|
||||
bool CommandLine::was_initialized()
|
||||
{
|
||||
return s_the != nullptr;
|
||||
}
|
||||
|
||||
const CommandLine& kernel_command_line()
|
||||
{
|
||||
VERIFY(s_the);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue