mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-30 15:41:12 +00:00
print error and return NULL when trying to create an invalid member access
This commit is contained in:
parent
fc7d32a715
commit
60a5d8ab4f
1 changed files with 5 additions and 0 deletions
5
ir.c
5
ir.c
|
@ -589,6 +589,11 @@ ir_value* ir_value_vector_member(ir_value *self, unsigned int member)
|
|||
self->members[member] = m;
|
||||
m->code.addroffset = member;
|
||||
}
|
||||
else
|
||||
{
|
||||
printf("invalid member access on %s\n", self->name);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return m;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue