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
9908c5d3
Commit
9908c5d3
authored
Oct 27, 2020
by
Huw Davies
Committed by
Alexandre Julliard
Oct 27, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
riched20: Fix the struct size check in the para fmt retrieval function.
Signed-off-by:
Huw Davies
<
huw@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
1abbb78a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
para.c
dlls/riched20/para.c
+5
-3
No files found.
dlls/riched20/para.c
View file @
9908c5d3
...
...
@@ -928,7 +928,8 @@ void ME_GetSelectionParaFormat(ME_TextEditor *editor, PARAFORMAT2 *pFmt)
ME_DisplayItem
*
para
,
*
para_end
;
PARAFORMAT2
*
curFmt
;
if
(
pFmt
->
cbSize
<
sizeof
(
PARAFORMAT
))
{
if
(
pFmt
->
cbSize
<
sizeof
(
PARAFORMAT
))
{
pFmt
->
dwMask
=
0
;
return
;
}
...
...
@@ -951,13 +952,14 @@ void ME_GetSelectionParaFormat(ME_TextEditor *editor, PARAFORMAT2 *pFmt)
CHECK_FIELD
(
PFM_RIGHTINDENT
,
dxRightIndent
);
CHECK_FIELD
(
PFM_OFFSET
,
dxOffset
);
CHECK_FIELD
(
PFM_ALIGNMENT
,
wAlignment
);
if
(
pFmt
->
dwMask
&
PFM_TABSTOPS
)
{
if
(
pFmt
->
dwMask
&
PFM_TABSTOPS
)
{
if
(
pFmt
->
cTabCount
!=
para
->
member
.
para
.
fmt
.
cTabCount
||
memcmp
(
pFmt
->
rgxTabs
,
curFmt
->
rgxTabs
,
curFmt
->
cTabCount
*
sizeof
(
int
)))
pFmt
->
dwMask
&=
~
PFM_TABSTOPS
;
}
if
(
pFmt
->
dwMask
>=
sizeof
(
PARAFORMAT2
))
if
(
pFmt
->
cbSize
>=
sizeof
(
PARAFORMAT2
))
{
pFmt
->
dwMask
&=
~
((
pFmt
->
wEffects
^
curFmt
->
wEffects
)
<<
16
);
CHECK_FIELD
(
PFM_SPACEBEFORE
,
dySpaceBefore
);
...
...
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