mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-10 23:01:50 +00:00
- Add NULL pointer to check to FWeaponSlot::PickWeapon() (for when this is called outside of a game).
SVN r3186 (trunk)
This commit is contained in:
parent
619634c1f8
commit
2effba9504
1 changed files with 4 additions and 0 deletions
|
@ -757,6 +757,10 @@ AWeapon *FWeaponSlot::PickWeapon(player_t *player, bool checkammo)
|
|||
{
|
||||
int i, j;
|
||||
|
||||
if (player->mo == NULL)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
// Does this slot even have any weapons?
|
||||
if (Weapons.Size() == 0)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue