mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-25 13:41:05 +00:00
Fixed potential crash when calling undefined function in ZScript
The following code which uses explicit class specifier led to a crash: class C { void F() { Object.Undefined(); } }
This commit is contained in:
parent
b9a2398935
commit
d50ba4954a
1 changed files with 1 additions and 1 deletions
|
@ -8091,7 +8091,7 @@ FxExpression *FxMemberFunctionCall::Resolve(FCompileContext& ctx)
|
|||
{
|
||||
bool error;
|
||||
PFunction *afd = FindClassMemberFunction(ccls, ctx.Class, MethodName, ScriptPosition, &error);
|
||||
if ((afd->Variants[0].Flags & VARF_Method) && (afd->Variants[0].Flags & VARF_Virtual))
|
||||
if ((nullptr != afd) && (afd->Variants[0].Flags & VARF_Method) && (afd->Variants[0].Flags & VARF_Virtual))
|
||||
{
|
||||
staticonly = false;
|
||||
novirtual = true;
|
||||
|
|
Loading…
Reference in a new issue