Commit 485811cf authored by Huw Davies's avatar Huw Davies Committed by Alexandre Julliard

ole32: Explicitly add the three ULONGs from the METAFILEPICT struct to allow for…

ole32: Explicitly add the three ULONGs from the METAFILEPICT struct to allow for padding in the 64-bit version.
parent 3aa266f8
......@@ -1390,7 +1390,7 @@ ULONG __RPC_USER HMETAFILEPICT_UserSize(ULONG *pFlags, ULONG StartingSize, HMETA
METAFILEPICT *mfpict = GlobalLock(*phMfp);
/* FIXME: raise an exception if mfpict is NULL? */
size += FIELD_OFFSET(remoteMETAFILEPICT, hMF);
size += 3 * sizeof(ULONG);
size += sizeof(ULONG);
size = HMETAFILE_UserSize(pFlags, size, &mfpict->hMF);
......@@ -1451,7 +1451,7 @@ unsigned char * __RPC_USER HMETAFILEPICT_UserMarshal(ULONG *pFlags, unsigned cha
remmfpict->mm = mfpict->mm;
remmfpict->xExt = mfpict->xExt;
remmfpict->yExt = mfpict->yExt;
pBuffer += FIELD_OFFSET(remoteMETAFILEPICT, hMF);
pBuffer += 3 * sizeof(ULONG);
*(ULONG *)pBuffer = USER_MARSHAL_PTR_PREFIX;
pBuffer += sizeof(ULONG);
......@@ -1518,7 +1518,7 @@ unsigned char * __RPC_USER HMETAFILEPICT_UserUnmarshal(ULONG *pFlags, unsigned c
mfpict->mm = remmfpict->mm;
mfpict->xExt = remmfpict->xExt;
mfpict->yExt = remmfpict->yExt;
pBuffer += FIELD_OFFSET(remoteMETAFILEPICT, hMF);
pBuffer += 3 * sizeof(ULONG);
user_marshal_prefix = *(ULONG *)pBuffer;
pBuffer += sizeof(ULONG);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment