mirror of https://github.com/acidanthera/audk.git
ShellPkg: cast return value to correct type based on what we passed in.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jaben Carsey <Jaben.carsey@intel.com> Reviewed-by: Joe Peterson <joe.peterson@intel.com> Reviewed-by: Shumin Qiu <shumin.qiu@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16734 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
69c569bf55
commit
432bf14cf1
|
@ -1302,9 +1302,9 @@ StripUnreplacedEnvironmentVariables(
|
||||||
CHAR16 *CurrentLocator;
|
CHAR16 *CurrentLocator;
|
||||||
|
|
||||||
for (CurrentLocator = CmdLine ; CurrentLocator != NULL ; ) {
|
for (CurrentLocator = CmdLine ; CurrentLocator != NULL ; ) {
|
||||||
FirstQuote = FindFirstCharacter(CurrentLocator, L"\"", L'^');
|
FirstQuote = (CHAR16*)FindFirstCharacter(CurrentLocator, L"\"", L'^');
|
||||||
FirstPercent = FindFirstCharacter(CurrentLocator, L"%", L'^');
|
FirstPercent = (CHAR16*)FindFirstCharacter(CurrentLocator, L"%", L'^');
|
||||||
SecondPercent = FirstPercent!=NULL?FindFirstCharacter(FirstPercent+1, L"%", L'^'):NULL;
|
SecondPercent = FirstPercent!=NULL?(CHAR16*)FindFirstCharacter(FirstPercent+1, L"%", L'^'):NULL;
|
||||||
if (FirstPercent == NULL || SecondPercent == NULL) {
|
if (FirstPercent == NULL || SecondPercent == NULL) {
|
||||||
//
|
//
|
||||||
// If we ever dont have 2 % we are done.
|
// If we ever dont have 2 % we are done.
|
||||||
|
@ -1313,7 +1313,7 @@ StripUnreplacedEnvironmentVariables(
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FirstQuote!= NULL && FirstQuote < FirstPercent) {
|
if (FirstQuote!= NULL && FirstQuote < FirstPercent) {
|
||||||
SecondQuote = FindFirstCharacter(FirstQuote+1, L"\"", L'^');
|
SecondQuote = (CHAR16*)FindFirstCharacter(FirstQuote+1, L"\"", L'^');
|
||||||
//
|
//
|
||||||
// Quote is first found
|
// Quote is first found
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in New Issue