From 432bf14cf11043cb6d95a4a436798c91cf0b29cf Mon Sep 17 00:00:00 2001 From: Jaben Carsey Date: Wed, 4 Feb 2015 01:23:14 +0000 Subject: 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 Reviewed-by: Joe Peterson Reviewed-by: Shumin Qiu git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16734 6f19259b-4bc3-4df7-8a09-765794883524 --- ShellPkg/Application/Shell/Shell.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ShellPkg') diff --git a/ShellPkg/Application/Shell/Shell.c b/ShellPkg/Application/Shell/Shell.c index ba071e58ed..dbf4d61aa9 100644 --- a/ShellPkg/Application/Shell/Shell.c +++ b/ShellPkg/Application/Shell/Shell.c @@ -1302,9 +1302,9 @@ StripUnreplacedEnvironmentVariables( CHAR16 *CurrentLocator; for (CurrentLocator = CmdLine ; CurrentLocator != NULL ; ) { - FirstQuote = FindFirstCharacter(CurrentLocator, L"\"", L'^'); - FirstPercent = FindFirstCharacter(CurrentLocator, L"%", L'^'); - SecondPercent = FirstPercent!=NULL?FindFirstCharacter(FirstPercent+1, L"%", L'^'):NULL; + FirstQuote = (CHAR16*)FindFirstCharacter(CurrentLocator, L"\"", L'^'); + FirstPercent = (CHAR16*)FindFirstCharacter(CurrentLocator, L"%", L'^'); + SecondPercent = FirstPercent!=NULL?(CHAR16*)FindFirstCharacter(FirstPercent+1, L"%", L'^'):NULL; if (FirstPercent == NULL || SecondPercent == NULL) { // // If we ever dont have 2 % we are done. @@ -1313,7 +1313,7 @@ StripUnreplacedEnvironmentVariables( } if (FirstQuote!= NULL && FirstQuote < FirstPercent) { - SecondQuote = FindFirstCharacter(FirstQuote+1, L"\"", L'^'); + SecondQuote = (CHAR16*)FindFirstCharacter(FirstQuote+1, L"\"", L'^'); // // Quote is first found // -- cgit v1.2.3