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
ce60eb84
Commit
ce60eb84
authored
Sep 06, 2011
by
Octavian Voicu
Committed by
Alexandre Julliard
Sep 06, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Fix two buffer overflow conditions in RtlDosPathNameToNtPathName_U.
parent
4e760d89
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
path.c
dlls/ntdll/path.c
+7
-1
No files found.
dlls/ntdll/path.c
View file @
ce60eb84
...
@@ -383,8 +383,14 @@ BOOLEAN WINAPI RtlDosPathNameToNtPathName_U(PCWSTR dos_path,
...
@@ -383,8 +383,14 @@ BOOLEAN WINAPI RtlDosPathNameToNtPathName_U(PCWSTR dos_path,
if
(
!
(
ptr
=
RtlAllocateHeap
(
GetProcessHeap
(),
0
,
sz
)))
return
FALSE
;
if
(
!
(
ptr
=
RtlAllocateHeap
(
GetProcessHeap
(),
0
,
sz
)))
return
FALSE
;
sz
=
RtlGetFullPathName_U
(
dos_path
,
sz
,
ptr
,
file_part
);
sz
=
RtlGetFullPathName_U
(
dos_path
,
sz
,
ptr
,
file_part
);
}
}
sz
+=
(
1
/* NUL */
+
4
/* unc\ */
+
4
/* \??\ */
)
*
sizeof
(
WCHAR
);
if
(
sz
>
MAXWORD
)
{
if
(
ptr
!=
local
)
RtlFreeHeap
(
GetProcessHeap
(),
0
,
ptr
);
return
FALSE
;
}
ntpath
->
MaximumLength
=
sz
+
(
4
/* unc\ */
+
4
/* \??\ */
)
*
sizeof
(
WCHAR
)
;
ntpath
->
MaximumLength
=
sz
;
ntpath
->
Buffer
=
RtlAllocateHeap
(
GetProcessHeap
(),
0
,
ntpath
->
MaximumLength
);
ntpath
->
Buffer
=
RtlAllocateHeap
(
GetProcessHeap
(),
0
,
ntpath
->
MaximumLength
);
if
(
!
ntpath
->
Buffer
)
if
(
!
ntpath
->
Buffer
)
{
{
...
...
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