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
05b1aea2
Commit
05b1aea2
authored
Apr 08, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Avoid reading bits outside of the glyph bitmap in GetGlyphOutline.
parent
45c9ec0d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
8 deletions
+5
-8
freetype.c
dlls/gdi32/freetype.c
+5
-8
No files found.
dlls/gdi32/freetype.c
View file @
05b1aea2
...
...
@@ -4939,14 +4939,10 @@ DWORD WineEngGetGlyphOutline(GdiFont *incoming_font, UINT glyph, UINT format,
BYTE
*
src
=
ft_face
->
glyph
->
bitmap
.
buffer
,
*
dst
=
buf
;
INT
h
=
ft_face
->
glyph
->
bitmap
.
rows
;
INT
x
;
memset
(
buf
,
0
,
needed
);
while
(
h
--
)
{
for
(
x
=
0
;
x
<
pitch
;
x
++
)
{
if
(
x
<
ft_face
->
glyph
->
bitmap
.
width
)
dst
[
x
]
=
(
src
[
x
/
8
]
&
(
1
<<
(
(
7
-
(
x
%
8
)))))
?
0xff
:
0
;
else
dst
[
x
]
=
0
;
}
for
(
x
=
0
;
x
<
pitch
&&
x
<
ft_face
->
glyph
->
bitmap
.
width
;
x
++
)
if
(
src
[
x
/
8
]
&
(
1
<<
(
(
7
-
(
x
%
8
)))))
dst
[
x
]
=
0xff
;
src
+=
ft_face
->
glyph
->
bitmap
.
pitch
;
dst
+=
pitch
;
}
...
...
@@ -5025,9 +5021,10 @@ DWORD WineEngGetGlyphOutline(GdiFont *incoming_font, UINT glyph, UINT format,
src
=
ft_face
->
glyph
->
bitmap
.
buffer
;
src_pitch
=
ft_face
->
glyph
->
bitmap
.
pitch
;
height
=
min
(
height
,
ft_face
->
glyph
->
bitmap
.
rows
);
while
(
height
--
)
{
for
(
x
=
0
;
x
<
width
;
x
++
)
for
(
x
=
0
;
x
<
width
&&
x
<
ft_face
->
glyph
->
bitmap
.
width
;
x
++
)
{
if
(
src
[
x
/
8
]
&
(
1
<<
(
(
7
-
(
x
%
8
))))
)
((
unsigned
int
*
)
dst
)[
x
]
=
~
0u
;
...
...
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