Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
fb724cfd
Commit
fb724cfd
authored
Nov 02, 2012
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Nov 02, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi.exe16: Use FIELD_OFFSET to calculate the size of structs with variable length array.
parent
e67deeb8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
gdi.c
dlls/gdi.exe16/gdi.c
+1
-1
metafile.c
dlls/gdi.exe16/metafile.c
+1
-1
No files found.
dlls/gdi.exe16/gdi.c
View file @
fb724cfd
...
...
@@ -1982,7 +1982,7 @@ void WINAPI SetRectRgn16( HRGN16 hrgn, INT16 left, INT16 top, INT16 right, INT16
*/
void
WINAPI
PlayMetaFileRecord16
(
HDC16
hdc
,
HANDLETABLE16
*
ht
,
METARECORD
*
mr
,
UINT16
handles
)
{
HANDLETABLE
*
ht32
=
HeapAlloc
(
GetProcessHeap
(),
0
,
handles
*
sizeof
(
*
ht32
)
);
HANDLETABLE
*
ht32
=
HeapAlloc
(
GetProcessHeap
(),
0
,
FIELD_OFFSET
(
HANDLETABLE
,
objectHandle
[
handles
]
)
);
unsigned
int
i
;
for
(
i
=
0
;
i
<
handles
;
i
++
)
ht32
->
objectHandle
[
i
]
=
HGDIOBJ_32
(
ht
->
objectHandle
[
i
]);
...
...
dlls/gdi.exe16/metafile.c
View file @
fb724cfd
...
...
@@ -213,7 +213,7 @@ BOOL16 WINAPI EnumMetaFile16( HDC16 hdc16, HMETAFILE16 hmf,
/* create the handle table */
hHT
=
GlobalAlloc16
(
GMEM_MOVEABLE
|
GMEM_ZEROINIT
,
sizeof
(
HANDLETABLE16
)
*
mh
->
mtNoObjects
);
FIELD_OFFSET
(
HANDLETABLE16
,
objectHandle
[
mh
->
mtNoObjects
])
);
spht
=
WOWGlobalLock16
(
hHT
);
seg
=
hmf
|
7
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment