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
bb1f8edc
Commit
bb1f8edc
authored
Nov 10, 2006
by
Mike McCormack
Committed by
Alexandre Julliard
Nov 10, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
riched20: Fix a memory leak.
parent
0f6c58c1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
4 deletions
+10
-4
editor.c
dlls/riched20/editor.c
+10
-4
No files found.
dlls/riched20/editor.c
View file @
bb1f8edc
...
...
@@ -2201,20 +2201,26 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
FINDTEXTA
*
ft
=
(
FINDTEXTA
*
)
lParam
;
int
nChars
=
MultiByteToWideChar
(
CP_ACP
,
0
,
ft
->
lpstrText
,
-
1
,
NULL
,
0
);
WCHAR
*
tmp
;
LRESULT
r
;
if
((
tmp
=
ALLOC_N_OBJ
(
WCHAR
,
nChars
))
!=
NULL
)
MultiByteToWideChar
(
CP_ACP
,
0
,
ft
->
lpstrText
,
-
1
,
tmp
,
nChars
);
return
ME_FindText
(
editor
,
wParam
,
&
ft
->
chrg
,
tmp
,
NULL
);
r
=
ME_FindText
(
editor
,
wParam
,
&
ft
->
chrg
,
tmp
,
NULL
);
FREE_OBJ
(
tmp
);
return
r
;
}
case
EM_FINDTEXTEX
:
{
FINDTEXTEXA
*
ex
=
(
FINDTEXTEXA
*
)
lParam
;
int
nChars
=
MultiByteToWideChar
(
CP_ACP
,
0
,
ex
->
lpstrText
,
-
1
,
NULL
,
0
);
WCHAR
*
tmp
;
LRESULT
r
;
if
((
tmp
=
ALLOC_N_OBJ
(
WCHAR
,
nChars
))
!=
NULL
)
MultiByteToWideChar
(
CP_ACP
,
0
,
ex
->
lpstrText
,
-
1
,
tmp
,
nChars
);
return
ME_FindText
(
editor
,
wParam
,
&
ex
->
chrg
,
tmp
,
&
ex
->
chrgText
);
r
=
ME_FindText
(
editor
,
wParam
,
&
ex
->
chrg
,
tmp
,
&
ex
->
chrgText
);
FREE_OBJ
(
tmp
);
return
r
;
}
case
EM_FINDTEXTW
:
{
...
...
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