Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ShellPkg: Fix check on OldArgv in UpdateArgcArgv()
The UpdateArgcArgv() function documentation says "If OldArgv or OldArgc is NULL then that value is not returned." However, only OldArgc was checked for NULL, probably because of copy-pasto. In case OldArgc was non-NULL, but OldArgv was null, it could cause a segmentation fault. Check OldArgv is not NULL before dereferencing the value. Signed-off-by: Tormod Volden <[email protected]>
- Loading branch information