summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
Diffstat (limited to 'src/map')
-rw-r--r--src/map/pet.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/map/pet.c b/src/map/pet.c
index a8e99df6c..553f64044 100644
--- a/src/map/pet.c
+++ b/src/map/pet.c
@@ -610,7 +610,8 @@ int pet_remove_map(struct map_session_data *sd)
pet_hungry_timer_delete(sd);
clif_clearchar_area(&sd->pd->bl,0);
map_delblock(&sd->pd->bl);
- free(sd->pd->lootitem);
+ if (sd->pd->lootitem)
+ aFree(sd->pd->lootitem);
map_deliddb(&sd->pd->bl);
}
return 0;