Fixed a possible NRE (raised with Glu)

This commit is contained in:
the_fiddler 2008-01-15 09:34:01 +00:00
parent 38df75ed51
commit e65c0c13e7

View file

@ -264,7 +264,8 @@ namespace Bind.Structures
Pointer = false; Pointer = false;
WrapperType = WrapperTypes.None; 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"; CurrentType = "IntPtr";
Pointer = false; Pointer = false;
@ -273,7 +274,7 @@ namespace Bind.Structures
} }
if (Reference) if (Reference)
WrapperType = WrapperTypes.ReferenceParameter; WrapperType |= WrapperTypes.ReferenceParameter;
// This causes problems with bool arrays // This causes problems with bool arrays
//if (CurrentType.ToLower().Contains("bool")) //if (CurrentType.ToLower().Contains("bool"))