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
60c8dfdd
Commit
60c8dfdd
authored
May 06, 2021
by
Hugh McMaster
Committed by
Alexandre Julliard
May 06, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reg: Prevent buffer over-read when querying REG_NONE values with no data.
Signed-off-by:
Hugh McMaster
<
hugh.mcmaster@outlook.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
1dd785d1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
query.c
programs/reg/query.c
+8
-0
No files found.
programs/reg/query.c
View file @
60c8dfdd
...
...
@@ -50,7 +50,15 @@ static WCHAR *reg_data_to_wchar(DWORD type, const BYTE *src, DWORD size_bytes)
WCHAR
*
ptr
;
buffer
=
malloc
((
size_bytes
*
2
+
1
)
*
sizeof
(
WCHAR
));
if
(
!
size_bytes
)
{
*
buffer
=
0
;
break
;
}
ptr
=
buffer
;
for
(
i
=
0
;
i
<
size_bytes
;
i
++
)
ptr
+=
swprintf
(
ptr
,
3
,
L"%02X"
,
src
[
i
]);
break
;
...
...
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