Specifications
16 Version 2.0
EFI_SHELL_PROTOCOL.Execute()
Summary
Execute the command line.
Prototype
typedef
EFI_STATUS
(EFIAPI *EFI_SHELL_EXECUTE) (
IN EFI_HANDLE *ParentImageHandle,
IN CHAR16 *CommandLine OPTIONAL,
IN CHAR16 **Environment OPTIONAL,
OUT EFI_STATUS *StatusCode OPTIONAL
);
Parameters
ParentImageHandle
A handle of the image that is executing the specified command line.
CommandLine
Points to the null-terminated UCS-2 encoded string containing the command line.
If NULL then the command-line will be empty.
Environment
Points to a null-terminated array of environment variables with the format ‘x=y’,
where x is the environment variable name and y is the value. If this is NULL,
then the current shell environment is used.
ErrorCode
Points to the status code returned by the command.
Description
This function creates a nested instance of the shell and executes the specified
command (CommandLine) with the specified environment (Environment). Upon return,
the status code returned by the specified command is placed in StatusCode.
If Environment is NULL, then the current environment is used and all changes made
by the commands executed will be reflected in the current environment. If the
Environment is non-NULL, then the changes made will be discarded.
The CommandLine is executed from the current working directory on the current
device.
Status Codes Returned
EFI_SUCCESS The command executed successfully. The
status code returned by the command is










