Commit 2dbb23c8 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

ole32: Free *ppszProgID on error path (Coverity).

parent fc179497
...@@ -2033,8 +2033,11 @@ HRESULT WINAPI ProgIDFromCLSID(REFCLSID clsid, LPOLESTR *ppszProgID) ...@@ -2033,8 +2033,11 @@ HRESULT WINAPI ProgIDFromCLSID(REFCLSID clsid, LPOLESTR *ppszProgID)
*ppszProgID = CoTaskMemAlloc(progidlen * sizeof(WCHAR)); *ppszProgID = CoTaskMemAlloc(progidlen * sizeof(WCHAR));
if (*ppszProgID) if (*ppszProgID)
{ {
if (RegQueryValueW(hkey, NULL, *ppszProgID, &progidlen)) if (RegQueryValueW(hkey, NULL, *ppszProgID, &progidlen)) {
ret = REGDB_E_CLASSNOTREG; ret = REGDB_E_CLASSNOTREG;
CoTaskMemFree(*ppszProgID);
*ppszProgID = NULL;
}
} }
else else
ret = E_OUTOFMEMORY; ret = E_OUTOFMEMORY;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment