[PATCH 2/2] oleaut32: Use VariantInit() rather than open coding it.

Huw Davies huw at codeweavers.com
Tue Apr 18 06:07:03 CDT 2017


Signed-off-by: Huw Davies <huw at codeweavers.com>
---
 dlls/oleaut32/vartype.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/oleaut32/vartype.c b/dlls/oleaut32/vartype.c
index ebb6183e4e..2151fc9d7f 100644
--- a/dlls/oleaut32/vartype.c
+++ b/dlls/oleaut32/vartype.c
@@ -129,7 +129,7 @@ static HRESULT VARIANT_FromDisp(IDispatch* pdispIn, LCID lcid, void* pOut,
   if (SUCCEEDED(hRet))
   {
     /* Convert the property to the requested type */
-    V_VT(&dstVar) = VT_EMPTY;
+    VariantInit(&dstVar);
     hRet = VariantChangeTypeEx(&dstVar, &srcVar, lcid, dwFlags, vt);
     VariantClear(&srcVar);
 
-- 
2.12.0




More information about the wine-patches mailing list