mirror of
https://github.com/reactos/reactos.git
synced 2024-11-23 11:33:31 +08:00
[SHELL32] CQueryAssociation: Add slash check (#6676)
Follow-up to #6656. I had forgotten to check the slash. JIRA issue: CORE-19493 Add StrChrW(pszAssoc, L'\\') check before PathFindExtensionW call.
This commit is contained in:
parent
f9a5585870
commit
72a27e6d45
@ -98,9 +98,12 @@ HRESULT STDMETHODCALLTYPE CQueryAssociations::Init(
|
||||
HRESULT hr;
|
||||
LPCWSTR pchDotExt;
|
||||
|
||||
pchDotExt = PathFindExtensionW(pszAssoc);
|
||||
if (pchDotExt && *pchDotExt)
|
||||
pszAssoc = pchDotExt;
|
||||
if (StrChrW(pszAssoc, L'\\'))
|
||||
{
|
||||
pchDotExt = PathFindExtensionW(pszAssoc);
|
||||
if (pchDotExt && *pchDotExt)
|
||||
pszAssoc = pchDotExt;
|
||||
}
|
||||
|
||||
LONG ret = RegOpenKeyExW(HKEY_CLASSES_ROOT,
|
||||
pszAssoc,
|
||||
|
Loading…
Reference in New Issue
Block a user