[PATCH] oleaut32: Check pointer before writing (eterbug #8241)

Konstantin Kondratyuk kondratyuk на etersoft.ru
Ср Апр 4 18:57:17 MSK 2012


---
 dlls/oleaut32/typelib2.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/dlls/oleaut32/typelib2.c b/dlls/oleaut32/typelib2.c
index fd4e547..a317362 100644
--- a/dlls/oleaut32/typelib2.c
+++ b/dlls/oleaut32/typelib2.c
@@ -3715,7 +3715,9 @@ static HRESULT WINAPI ITypeInfo2_fnGetContainingTypeLib(
 
     *ppTLib = (ITypeLib *)&This->typelib->ITypeLib2_iface;
     ICreateTypeLib_AddRef((ICreateTypeLib*)This->typelib);
-    *pIndex = This->typeinfo->typekind >> 16;
+
+    if(pIndex)
+        *pIndex = This->typeinfo->typekind >> 16;
 
     return S_OK;
 }
-- 
1.7.9.5


--nextPart3453456.Snpsb19rcI--



Подробная информация о списке рассылки Wine-patches