Commit 9776f5b8 authored by Stefan Siebert's avatar Stefan Siebert Committed by Alexandre Julliard

oleaut32: GetTypeInfoType - Return TYPE_E_ELEMENTNOTFOUND if index out of bounds.

parent f740a280
......@@ -3602,6 +3602,9 @@ static HRESULT WINAPI ITypeLib2_fnGetTypeInfoType(
ITypeLibImpl *This = (ITypeLibImpl *)iface;
int i;
ITypeInfoImpl *pTInfo = This->pTypeInfo;
if ((ITypeLib2_fnGetTypeInfoCount(iface) < index + 1) || (index < 0))
return TYPE_E_ELEMENTNOTFOUND;
TRACE("(%p) index %d\n", This, index);
......
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