Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
a528ddd7
Commit
a528ddd7
authored
Apr 30, 2017
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 01, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32/shellview: Handle NULL folder pointer in SHCreateShellFolderViewEx().
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
7a49da50
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
shlview.c
dlls/shell32/shlview.c
+3
-0
shlview.c
dlls/shell32/tests/shlview.c
+10
-0
No files found.
dlls/shell32/shlview.c
View file @
a528ddd7
...
...
@@ -3806,6 +3806,9 @@ HRESULT WINAPI SHCreateShellFolderViewEx(CSFV *desc, IShellView **shellview)
TRACE
(
"sf=%p pidl=%p cb=%p mode=0x%08x parm=%p
\n
"
,
desc
->
pshf
,
desc
->
pidl
,
desc
->
pfnCallback
,
desc
->
fvm
,
desc
->
psvOuter
);
if
(
!
desc
->
pshf
)
return
E_UNEXPECTED
;
*
shellview
=
IShellView_Constructor
(
desc
->
pshf
);
if
(
!*
shellview
)
return
E_OUTOFMEMORY
;
...
...
dlls/shell32/tests/shlview.c
View file @
a528ddd7
...
...
@@ -1433,6 +1433,16 @@ static void test_SHCreateShellFolderViewEx(void)
ok
(
refCount
==
0
,
"refCount = %u
\n
"
,
refCount
);
}
if
(
0
)
{
/* Crashes on null shellfolder, on XP/2k3 */
memset
(
&
csfv
,
0
,
sizeof
(
csfv
));
csfv
.
pshf
=
NULL
;
psv
=
(
void
*
)
0xdeadbeef
;
hr
=
SHCreateShellFolderViewEx
(
&
csfv
,
&
psv
);
ok
(
hr
==
E_UNEXPECTED
,
"Got 0x%08x
\n
"
,
hr
);
ok
(
psv
==
NULL
,
"psv = %p
\n
"
,
psv
);
}
memset
(
&
csfv
,
0
,
sizeof
(
csfv
));
csfv
.
cbSize
=
sizeof
(
csfv
);
csfv
.
pshf
=
desktop
;
...
...
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