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
663f9f4b
Commit
663f9f4b
authored
Jul 15, 2015
by
Piotr Caban
Committed by
Alexandre Julliard
Jul 16, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32: Handle executable with space in path in SHELL_execute.
parent
8e853a3e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
5 deletions
+8
-5
shlexec.c
dlls/shell32/shlexec.c
+8
-5
No files found.
dlls/shell32/shlexec.c
View file @
663f9f4b
...
...
@@ -1554,7 +1554,6 @@ static void do_error_dialog( UINT_PTR retval, HWND hwnd )
*/
static
BOOL
SHELL_execute
(
LPSHELLEXECUTEINFOW
sei
,
SHELL_ExecuteW32
execfunc
)
{
static
const
WCHAR
wSpace
[]
=
{
' '
,
0
};
static
const
WCHAR
wWww
[]
=
{
'w'
,
'w'
,
'w'
,
0
};
static
const
WCHAR
wHttp
[]
=
{
'h'
,
't'
,
't'
,
'p'
,
':'
,
'/'
,
'/'
,
0
};
static
const
DWORD
unsupportedFlags
=
...
...
@@ -1763,7 +1762,7 @@ static BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc )
TRACE
(
"execute:%s,%s,%s
\n
"
,
debugstr_w
(
wszApplicationName
),
debugstr_w
(
wszParameters
),
debugstr_w
(
wszDir
));
lpFile
=
sei_tmp
.
lpFile
;
wcmd
=
wcmdBuffer
;
len
=
lstrlenW
(
wszApplicationName
)
+
1
;
len
=
lstrlenW
(
wszApplicationName
)
+
3
;
if
(
sei_tmp
.
lpParameters
[
0
])
len
+=
1
+
lstrlenW
(
wszParameters
);
if
(
len
>
wcmdLen
)
...
...
@@ -1771,10 +1770,14 @@ static BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc )
wcmd
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
*
sizeof
(
WCHAR
));
wcmdLen
=
len
;
}
strcpyW
(
wcmd
,
wszApplicationName
);
wcmd
[
0
]
=
'\"'
;
len
=
lstrlenW
(
wszApplicationName
);
memcpy
(
wcmd
+
1
,
wszApplicationName
,
len
*
sizeof
(
WCHAR
));
len
++
;
wcmd
[
len
++
]
=
'\"'
;
if
(
sei_tmp
.
lpParameters
[
0
])
{
strcatW
(
wcmd
,
wSpace
)
;
strc
atW
(
wcmd
,
wszParameters
);
wcmd
[
len
++
]
=
' '
;
strc
pyW
(
wcmd
+
len
,
wszParameters
);
}
retval
=
execfunc
(
wcmd
,
NULL
,
FALSE
,
&
sei_tmp
,
sei
);
...
...
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