Base: Prevent crash when trying to create badType instance
This commit is contained in:
@@ -84,7 +84,8 @@ Type::~Type()
|
||||
|
||||
void *Type::createInstance()
|
||||
{
|
||||
return (typedata[index]->instMethod)();
|
||||
instantiationMethod method = typedata[index]->instMethod;
|
||||
return method ? (*method)() : nullptr;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user