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
4e5698f7
Commit
4e5698f7
authored
May 29, 2016
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 30, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ole32: Don't try to read key value if key was not found (Valgrind).
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
47043b92
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
8 deletions
+11
-8
moniker.c
dlls/ole32/moniker.c
+11
-8
No files found.
dlls/ole32/moniker.c
View file @
4e5698f7
...
...
@@ -1265,13 +1265,17 @@ HRESULT WINAPI GetClassFile(LPCOLESTR filePathName,CLSID *pclsid)
}
ret
=
RegQueryValueW
(
HKEY_CLASSES_ROOT
,
extension
,
NULL
,
&
sizeProgId
);
/* get the progId associated to the extension */
progId
=
CoTaskMemAlloc
(
sizeProgId
);
ret
=
RegQueryValueW
(
HKEY_CLASSES_ROOT
,
extension
,
progId
,
&
sizeProgId
);
if
(
!
ret
)
/* return the clsid associated to the progId */
res
=
CLSIDFromProgID
(
progId
,
pclsid
);
if
(
!
ret
)
{
/* get the progId associated to the extension */
progId
=
CoTaskMemAlloc
(
sizeProgId
);
ret
=
RegQueryValueW
(
HKEY_CLASSES_ROOT
,
extension
,
progId
,
&
sizeProgId
);
if
(
!
ret
)
/* return the clsid associated to the progId */
res
=
CLSIDFromProgID
(
progId
,
pclsid
);
else
res
=
HRESULT_FROM_WIN32
(
ret
);
CoTaskMemFree
(
progId
);
}
else
res
=
HRESULT_FROM_WIN32
(
ret
);
...
...
@@ -1279,7 +1283,6 @@ HRESULT WINAPI GetClassFile(LPCOLESTR filePathName,CLSID *pclsid)
CoTaskMemFree
(
pathDec
[
i
]);
CoTaskMemFree
(
pathDec
);
CoTaskMemFree
(
progId
);
return
res
!=
S_OK
?
MK_E_INVALIDEXTENSION
:
res
;
}
...
...
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