Initialize shell only once
This commit is contained in:
@@ -307,6 +307,24 @@ Shell::ExecuteCommand(IN ULONG Argc,
|
||||
Console::Print(L"ERROR: '%S' is not recognized as a valid command.\n", Argv[0]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the bootloader shell.
|
||||
*
|
||||
* @return This routine does not return any value.
|
||||
*
|
||||
* @since XT 1.0
|
||||
*/
|
||||
XTCDECL
|
||||
VOID
|
||||
Shell::InitializeShell()
|
||||
{
|
||||
/* Initialize the shell commands list */
|
||||
RTL::LinkedList::InitializeListHead(&ShellCommands);
|
||||
|
||||
/* Register all built-in commands */
|
||||
RegisterBuiltinCommands();
|
||||
}
|
||||
|
||||
/**
|
||||
* Splits the supplied raw command line string into an argument count and an argument vector suitable
|
||||
* for command dispatch. The input string is tokenized by whitespace.
|
||||
@@ -881,12 +899,6 @@ Shell::StartLoaderShell()
|
||||
/* Initialize console */
|
||||
Console::InitializeConsole();
|
||||
|
||||
/* Initialize the shell commands list */
|
||||
RTL::LinkedList::InitializeListHead(&ShellCommands);
|
||||
|
||||
/* Register all built-in commands */
|
||||
RegisterBuiltinCommands();
|
||||
|
||||
/* Clear the shell exit request flag */
|
||||
ExitRequest = FALSE;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user