From c5d00b30c1d6bb1198c9d1df30fe9865979253b4 Mon Sep 17 00:00:00 2001 From: klu2 Date: Wed, 7 Apr 2010 02:33:16 +0000 Subject: [PATCH] Fix the issue that GCC treat enum type as unsigned int which incompatible with UEFI spec's INT32. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10347 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Core/Dxe/Mem/Pool.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Core/Dxe/Mem/Pool.c b/MdeModulePkg/Core/Dxe/Mem/Pool.c index d92935991a..fe3234e9ac 100644 --- a/MdeModulePkg/Core/Dxe/Mem/Pool.c +++ b/MdeModulePkg/Core/Dxe/Mem/Pool.c @@ -1,7 +1,7 @@ /** @file UEFI Memory pool management functions. -Copyright (c) 2006 - 2008, Intel Corporation.
+Copyright (c) 2006 - 2010, Intel Corporation.
All rights reserved. This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -128,7 +128,7 @@ LookupPoolHead ( // MemoryType values in the range 0x80000000..0xFFFFFFFF are reserved for use by UEFI // OS loaders that are provided by operating system vendors // - if (MemoryType < 0) { + if (MemoryType >= (INT32)0x80000000 && MemoryType <= (INT32)0xffffffff) { for (Link = mPoolHeadList.ForwardLink; Link != &mPoolHeadList; Link = Link->ForwardLink) { Pool = CR(Link, POOL, Link, POOL_SIGNATURE); -- 2.39.2