James Hawkins : fusion: Align the metadata header pointer on a DWORD boundary.

Alexandre Julliard julliard at winehq.org
Tue Aug 19 08:46:36 CDT 2008


Module: wine
Branch: master
Commit: cfc68a96c785f29dc392ae9701c433aa44e1025e
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=cfc68a96c785f29dc392ae9701c433aa44e1025e

Author: James Hawkins <jhawkins at codeweavers.com>
Date:   Mon Aug 18 22:55:29 2008 -0500

fusion: Align the metadata header pointer on a DWORD boundary.

---

 dlls/fusion/assembly.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/fusion/assembly.c b/dlls/fusion/assembly.c
index fc44e49..75ca048 100644
--- a/dlls/fusion/assembly.c
+++ b/dlls/fusion/assembly.c
@@ -632,8 +632,8 @@ static HRESULT parse_clr_metadata(ASSEMBLY *assembly)
         else if (!lstrcmpA(stream, "#Blob") || !lstrcmpA(stream, "Blob"))
             assembly->blobs = (BYTE *)assembly_data_offset(assembly, ofs);
 
-        ptr += lstrlenA(stream);
-        while (!*ptr) ptr++;
+        ptr += lstrlenA(stream) + 1;
+        ptr = (BYTE *)(((UINT_PTR)ptr + 3) & ~3); /* align on DWORD boundary */
     }
 
     return S_OK;




More information about the wine-cvs mailing list