From: qhuang8 Date: Fri, 10 Apr 2009 04:27:35 +0000 (+0000) Subject: Add ASSERT() check for StringInfo pointer. X-Git-Tag: edk2-stable201903~18209 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=7b06dc8a9128d747cdebe79a89e1eb53c17c22fb Add ASSERT() check for StringInfo pointer. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8055 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c b/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c index dfb21673fd..fa87273259 100644 --- a/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c +++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c @@ -1585,6 +1585,10 @@ HiiStringToImage ( Background = SystemDefault->BackgroundColor; } else { + // + // StringInfo must not be NULL if it is not system info. + // + ASSERT (StringInfo != NULL); Status = HiiGetFontInfo (This, &FontHandle, (EFI_FONT_DISPLAY_INFO *) StringInfo, &StringInfoOut, NULL); if (Status == EFI_NOT_FOUND) { //