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
733bf916
Commit
733bf916
authored
Oct 09, 2023
by
Eric Pouech
Committed by
Alexandre Julliard
Oct 09, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp: Simplify allocation code.
Signed-off-by:
Eric Pouech
<
epouech@codeweavers.com
>
parent
bc7e51b4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
dbghelp.c
dlls/dbghelp/dbghelp.c
+3
-7
No files found.
dlls/dbghelp/dbghelp.c
View file @
733bf916
...
...
@@ -400,17 +400,13 @@ static BOOL check_live_target(struct process* pcs, BOOL wow64, BOOL child_wow64)
{
size_t
buf_size
=
0
,
i
,
last_null
=
-
1
;
WCHAR
*
buf
=
NULL
;
WCHAR
*
new_buf
;
do
{
size_t
read_size
=
sysinfo
.
dwAllocationGranularity
-
(
env
&
(
sysinfo
.
dwAllocationGranularity
-
1
));
if
(
buf
)
{
WCHAR
*
new_buf
;
if
(
!
(
new_buf
=
realloc
(
buf
,
buf_size
+
read_size
)))
break
;
buf
=
new_buf
;
}
else
if
(
!
(
buf
=
malloc
(
read_size
)))
break
;
if
(
!
(
new_buf
=
realloc
(
buf
,
buf_size
+
read_size
)))
break
;
buf
=
new_buf
;
if
(
!
read_process_memory
(
pcs
,
env
,
(
char
*
)
buf
+
buf_size
,
read_size
))
break
;
for
(
i
=
buf_size
/
sizeof
(
WCHAR
);
i
<
(
buf_size
+
read_size
)
/
sizeof
(
WCHAR
);
i
++
)
...
...
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