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
679df54b
Commit
679df54b
authored
Apr 07, 2006
by
Mike Hearn
Committed by
Alexandre Julliard
Apr 07, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel: Correct SearchPathA argument validation.
parent
ba626089
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
path.c
dlls/kernel/path.c
+5
-4
No files found.
dlls/kernel/path.c
View file @
679df54b
...
@@ -722,7 +722,7 @@ inline static BOOL contains_pathW (LPCWSTR name)
...
@@ -722,7 +722,7 @@ inline static BOOL contains_pathW (LPCWSTR name)
* Searches for a specified file in the search path.
* Searches for a specified file in the search path.
*
*
* PARAMS
* PARAMS
* path [I] Path to search
* path [I] Path to search
(NULL means default)
* name [I] Filename to search for.
* name [I] Filename to search for.
* ext [I] File extension to append to file name. The first
* ext [I] File extension to append to file name. The first
* character must be a period. This parameter is
* character must be a period. This parameter is
...
@@ -818,12 +818,13 @@ DWORD WINAPI SearchPathW( LPCWSTR path, LPCWSTR name, LPCWSTR ext, DWORD buflen,
...
@@ -818,12 +818,13 @@ DWORD WINAPI SearchPathW( LPCWSTR path, LPCWSTR name, LPCWSTR ext, DWORD buflen,
DWORD
WINAPI
SearchPathA
(
LPCSTR
path
,
LPCSTR
name
,
LPCSTR
ext
,
DWORD
WINAPI
SearchPathA
(
LPCSTR
path
,
LPCSTR
name
,
LPCSTR
ext
,
DWORD
buflen
,
LPSTR
buffer
,
LPSTR
*
lastpart
)
DWORD
buflen
,
LPSTR
buffer
,
LPSTR
*
lastpart
)
{
{
WCHAR
*
pathW
,
*
nameW
=
NULL
,
*
extW
=
NULL
;
WCHAR
*
pathW
=
NULL
,
*
nameW
=
NULL
,
*
extW
=
NULL
;
WCHAR
bufferW
[
MAX_PATH
];
WCHAR
bufferW
[
MAX_PATH
];
DWORD
ret
;
DWORD
ret
;
if
(
name
&&
!
(
nameW
=
FILE_name_AtoW
(
name
,
FALSE
)))
return
0
;
if
(
!
name
||
!
(
nameW
=
FILE_name_AtoW
(
name
,
FALSE
)))
return
0
;
if
(
!
(
pathW
=
FILE_name_AtoW
(
path
,
TRUE
)))
return
0
;
if
(
path
&&
!
(
pathW
=
FILE_name_AtoW
(
path
,
TRUE
)))
return
0
;
if
(
ext
&&
!
(
extW
=
FILE_name_AtoW
(
ext
,
TRUE
)))
if
(
ext
&&
!
(
extW
=
FILE_name_AtoW
(
ext
,
TRUE
)))
{
{
HeapFree
(
GetProcessHeap
(),
0
,
pathW
);
HeapFree
(
GetProcessHeap
(),
0
,
pathW
);
...
...
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