Core/Dxe/Misc: Fixed string comparison bug.

This commit is contained in:
Mikhail Krichanov 2024-09-05 13:40:09 +03:00
parent be8f6f968e
commit d4e1092dc7

View File

@ -236,7 +236,7 @@ ProtectUefiImage (
//
// CPU ARCH present. Update memory attribute directly.
//
if (PcdGetBool (PcdEnableUserSpace)) {
if (PcdGetBool (PcdEnableUserSpace) && (PdbPointer != NULL)) {
if (AsciiStrStr (PdbPointer, "Fat") != NULL) {
SetUefiImageProtectionAttributes (ImageRecord, TRUE);
*IsUserImage = TRUE;