diff options
author | Freeyorp <Freeyorp101@hotmail.com> | 2009-11-23 15:23:25 +1300 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-11-22 19:31:22 -0700 |
commit | afa9b43941415a5f995da3c8ec02d338c6ea8fd0 (patch) | |
tree | 89eba5c0a4f396990b5aea2122b85593409deded /src/map/mob.c | |
parent | d90bbe7517fd3bd51d4893cced5f20bcf314e601 (diff) | |
download | tmwa-afa9b43941415a5f995da3c8ec02d338c6ea8fd0.tar.gz tmwa-afa9b43941415a5f995da3c8ec02d338c6ea8fd0.tar.bz2 tmwa-afa9b43941415a5f995da3c8ec02d338c6ea8fd0.tar.xz tmwa-afa9b43941415a5f995da3c8ec02d338c6ea8fd0.zip |
Fix a segfault when the master of a summoned monster is not online
Diffstat (limited to 'src/map/mob.c')
-rw-r--r-- | src/map/mob.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/mob.c b/src/map/mob.c index 5a0bedc..f3822c4 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -2335,7 +2335,7 @@ int mob_damage(struct block_list *src,struct mob_data *md,int damage,int type) if(src && src->type == BL_MOB && ((struct mob_data*)src)->state.special_mob_ai){ struct mob_data *md2 = (struct mob_data *)src; struct block_list *master_bl = map_id2bl(md2->master_id); - if (master_bl->type == BL_PC) { + if (master_bl && master_bl->type == BL_PC) { MAP_LOG_PC(((struct map_session_data *)master_bl), "MOB-TO-MOB-DMG FROM MOB%d %d TO MOB%d %d FOR %d", md2->bl.id, md2->class, md->bl.id, md->class, |