ShellPkg/Shell: Fix reporting of exit status in ShellProtocol.Execute

When the exit status of the command run by the shell is other than
SHELL_SUCCESS, the shell image will now exit with EFI_ABORTED, placing the
commands exit status (which is a SHELL_STATUS) in ExitData.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Brendan Jackman <Brendan.Jackman@arm.com>
Reviewed-by: Olivier Martin <olivier.martin@arm.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>



git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15180 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Brendan Jackman
2014-01-24 22:27:11 +00:00
committed by oliviermartin
parent fed3be946c
commit 5223c12135
4 changed files with 236 additions and 64 deletions

View File

@ -443,6 +443,9 @@ EfiShellEnablePageBreak (
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.
@param[out] ExitDataSize ExitDataSize as returned from gBS->StartImage
@param[out] ExitData ExitData as returned from gBS->StartImage
@param StatusCode Points to the status code returned by the command.
@retval EFI_SUCCESS The command executed successfully. The status code
@ -458,7 +461,8 @@ InternalShellExecuteDevicePath(
IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath,
IN CONST CHAR16 *CommandLine OPTIONAL,
IN CONST CHAR16 **Environment OPTIONAL,
OUT EFI_STATUS *StatusCode OPTIONAL
OUT UINTN *ExitDataSize OPTIONAL,
OUT CHAR16 **ExitData OPTIONAL
);
/**