mirror of
https://github.com/yquake2/xatrix.git
synced 2024-11-10 06:42:22 +00:00
Fix potential nulllpointer dereferences
This commit is contained in:
parent
0226b07f48
commit
3e063fe549
3 changed files with 9 additions and 0 deletions
|
@ -937,6 +937,9 @@ void door_use (edict_t *self, edict_t *other, edict_t *activator)
|
||||||
{
|
{
|
||||||
edict_t *ent;
|
edict_t *ent;
|
||||||
|
|
||||||
|
if (!self)
|
||||||
|
return;
|
||||||
|
|
||||||
if (self->flags & FL_TEAMSLAVE)
|
if (self->flags & FL_TEAMSLAVE)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
|
@ -109,6 +109,9 @@ gitem_t *FindItem (char *pickup_name)
|
||||||
|
|
||||||
void DoRespawn (edict_t *ent)
|
void DoRespawn (edict_t *ent)
|
||||||
{
|
{
|
||||||
|
if (!ent)
|
||||||
|
return;
|
||||||
|
|
||||||
if (ent->team)
|
if (ent->team)
|
||||||
{
|
{
|
||||||
edict_t *master;
|
edict_t *master;
|
||||||
|
|
|
@ -687,6 +687,9 @@ void fire_rail (edict_t *self, vec3_t start, vec3_t aimdir, int damage, int kick
|
||||||
int mask;
|
int mask;
|
||||||
qboolean water;
|
qboolean water;
|
||||||
|
|
||||||
|
if (!self)
|
||||||
|
return;
|
||||||
|
|
||||||
VectorMA (start, 8192, aimdir, end);
|
VectorMA (start, 8192, aimdir, end);
|
||||||
VectorCopy (start, from);
|
VectorCopy (start, from);
|
||||||
ignore = self;
|
ignore = self;
|
||||||
|
|
Loading…
Reference in a new issue