Fixed a possible NRE (raised with Glu)

This commit is contained in:
the_fiddler 2008-01-15 09:34:01 +00:00
parent baf9b4d648
commit 53e9f7cc67

View file

@ -264,7 +264,8 @@ namespace Bind.Structures
Pointer = false;
WrapperType = WrapperTypes.None;
}
else if (CurrentType.ToLower().Contains("void") || PreviousType.ToLower().Contains("void")) /*|| CurrentType.Contains("IntPtr"))*/
else if (CurrentType.ToLower().Contains("void") ||
(!String.IsNullOrEmpty(PreviousType) && PreviousType.ToLower().Contains("void"))) /*|| CurrentType.Contains("IntPtr"))*/
{
CurrentType = "IntPtr";
Pointer = false;
@ -273,7 +274,7 @@ namespace Bind.Structures
}
if (Reference)
WrapperType = WrapperTypes.ReferenceParameter;
WrapperType |= WrapperTypes.ReferenceParameter;
// This causes problems with bool arrays
//if (CurrentType.ToLower().Contains("bool"))