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
53cf91bc
Commit
53cf91bc
authored
Nov 22, 2006
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Nov 22, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Restore the len == 0 check which got lost in a previous patch.
parent
8519a6c4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
static.c
dlls/user32/static.c
+7
-2
No files found.
dlls/user32/static.c
View file @
53cf91bc
...
...
@@ -682,14 +682,18 @@ static void STATIC_PaintTextfn( HWND hwnd, HDC hdc, DWORD style )
}
buf_size
=
256
;
if
(
!
(
text
=
HeapAlloc
(
GetProcessHeap
(),
0
,
buf_size
*
sizeof
(
WCHAR
)
)))
return
;
if
(
!
(
text
=
HeapAlloc
(
GetProcessHeap
(),
0
,
buf_size
*
sizeof
(
WCHAR
)
)))
goto
no_TextOut
;
while
((
len
=
InternalGetWindowText
(
hwnd
,
text
,
buf_size
))
==
buf_size
-
1
)
{
buf_size
*=
2
;
if
(
!
(
text
=
HeapReAlloc
(
GetProcessHeap
(),
0
,
text
,
buf_size
*
sizeof
(
WCHAR
)
)))
return
;
if
(
!
(
text
=
HeapReAlloc
(
GetProcessHeap
(),
0
,
text
,
buf_size
*
sizeof
(
WCHAR
)
)))
goto
no_TextOut
;
}
if
(
!
len
)
goto
no_TextOut
;
if
(((
style
&
SS_TYPEMASK
)
==
SS_SIMPLE
)
&&
(
style
&
SS_NOPREFIX
))
{
/* Windows uses the faster ExtTextOut() to draw the text and
...
...
@@ -703,6 +707,7 @@ static void STATIC_PaintTextfn( HWND hwnd, HDC hdc, DWORD style )
DrawTextW
(
hdc
,
text
,
-
1
,
&
rc
,
wFormat
);
}
no_TextOut:
HeapFree
(
GetProcessHeap
(),
0
,
text
);
if
(
hFont
)
...
...
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