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
f26874c5
Commit
f26874c5
authored
Jun 26, 2014
by
Christoph von Wittich
Committed by
Alexandre Julliard
Jun 27, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shlwapi: Avoid buffer overflow in PathCombineA.
parent
4b594361
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
path.c
dlls/shlwapi/path.c
+7
-6
No files found.
dlls/shlwapi/path.c
View file @
f26874c5
...
...
@@ -155,20 +155,21 @@ LPSTR WINAPI PathCombineA(LPSTR lpszDest, LPCSTR lpszDir, LPCSTR lpszFile)
if
(
!
lpszDest
)
return
NULL
;
if
(
!
lpszDir
&&
!
lpszFile
)
{
lpszDest
[
0
]
=
0
;
return
NULL
;
}
goto
fail
;
if
(
lpszDir
)
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszDir
,
-
1
,
szDir
,
MAX_PATH
);
if
(
!
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszDir
,
-
1
,
szDir
,
MAX_PATH
))
goto
fail
;
if
(
lpszFile
)
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
);
if
(
!
MultiByteToWideChar
(
CP_ACP
,
0
,
lpszFile
,
-
1
,
szFile
,
MAX_PATH
))
goto
fail
;
if
(
PathCombineW
(
szDest
,
lpszDir
?
szDir
:
NULL
,
lpszFile
?
szFile
:
NULL
))
if
(
WideCharToMultiByte
(
CP_ACP
,
0
,
szDest
,
-
1
,
lpszDest
,
MAX_PATH
,
0
,
0
))
return
lpszDest
;
fail:
lpszDest
[
0
]
=
0
;
return
NULL
;
}
...
...
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