Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
169a23a1
Commit
169a23a1
authored
Nov 27, 2023
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 30, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32/emf: Add description field padding.
parent
4fac4588
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
emfdc.c
dlls/gdi32/emfdc.c
+4
-2
No files found.
dlls/gdi32/emfdc.c
View file @
169a23a1
...
...
@@ -2638,6 +2638,7 @@ static struct emf *emf_create( HDC hdc, const RECT *rect, const WCHAR *descripti
DWORD
size
=
0
,
length
=
0
;
DC_ATTR
*
dc_attr
;
struct
emf
*
emf
;
void
*
ptr
;
if
(
!
(
dc_attr
=
get_dc_attr
(
hdc
))
||
!
(
emf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
*
emf
)
)))
return
NULL
;
...
...
@@ -2649,7 +2650,7 @@ static struct emf *emf_create( HDC hdc, const RECT *rect, const WCHAR *descripti
length
+=
3
;
length
*=
2
;
}
size
=
sizeof
(
ENHMETAHEADER
)
+
(
length
+
3
)
/
4
*
4
;
size
=
sizeof
(
ENHMETAHEADER
)
+
aligned_size
(
length
)
;
if
(
!
(
emf
->
emh
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
))
||
!
(
emf
->
handles
=
HeapAlloc
(
GetProcessHeap
(),
0
,
...
...
@@ -2674,7 +2675,8 @@ static struct emf *emf_create( HDC hdc, const RECT *rect, const WCHAR *descripti
emf
->
emh
->
nDescription
=
length
/
2
;
emf
->
emh
->
offDescription
=
length
?
sizeof
(
ENHMETAHEADER
)
:
0
;
memcpy
(
(
char
*
)
emf
->
emh
+
sizeof
(
ENHMETAHEADER
),
description
,
length
);
ptr
=
memcpy
(
(
char
*
)
emf
->
emh
+
sizeof
(
ENHMETAHEADER
),
description
,
length
);
pad_record
(
ptr
,
length
);
emf_reset
(
dc_attr
,
rect
);
return
emf
;
...
...
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