]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix ALIGN_POINTER() macro. The pointer (p) passed in must always be converted to...
authormdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 9 Nov 2006 22:01:56 +0000 (22:01 +0000)
committermdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 9 Nov 2006 22:01:56 +0000 (22:01 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1922 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Include/Common/BaseTypes.h

index 3935919300d053b3d71f49bc72a3754b7dac95a2..92e9c141f725800f2061420e98e68f4dcfc18cc5 100644 (file)
@@ -139,7 +139,7 @@ typedef CHAR8 *VA_LIST;
 ///\r
 ///  ALIGN_POINTER - aligns a pointer to the lowest boundry\r
 ///\r
 ///\r
 ///  ALIGN_POINTER - aligns a pointer to the lowest boundry\r
 ///\r
-#define ALIGN_POINTER(p, s) ((VOID *) ((p) + (((s) - ((UINTN) (p))) & ((s) - 1))))\r
+#define ALIGN_POINTER(p, s) ((VOID *) ((UINTN)(p) + (((s) - ((UINTN) (p))) & ((s) - 1))))\r
 \r
 ///\r
 ///  ALIGN_VARIABLE - aligns a variable up to the next natural boundry for int size of a processor\r
 \r
 ///\r
 ///  ALIGN_VARIABLE - aligns a variable up to the next natural boundry for int size of a processor\r