quartz: Fix variant handling in GetFilterInfo.

Removes unnecessary and unsafe type assignment, adds a missing VariantClear.
This commit is contained in:
Alexander Dorofeyev 2008-07-17 20:25:22 +03:00 committed by Alexandre Julliard
parent 7c5a4481b1
commit 1cd83afda3
1 changed files with 2 additions and 1 deletions

View File

@ -773,7 +773,6 @@ static HRESULT GetFilterInfo(IMoniker* pMoniker, GUID* pclsid, VARIANT* pvar)
HRESULT hr;
VariantInit(pvar);
V_VT(pvar) = VT_BSTR;
hr = IMoniker_BindToStorage(pMoniker, NULL, NULL, &IID_IPropertyBag, (LPVOID*)&pPropBagCat);
@ -783,6 +782,8 @@ static HRESULT GetFilterInfo(IMoniker* pMoniker, GUID* pclsid, VARIANT* pvar)
if (SUCCEEDED(hr))
hr = CLSIDFromString(V_UNION(pvar, bstrVal), pclsid);
VariantClear(pvar);
if (SUCCEEDED(hr))
hr = IPropertyBag_Read(pPropBagCat, wszFriendlyName, pvar, NULL);