From 7dab561f42bcc47199013d7a6c86e8aa2a9e6266 Mon Sep 17 00:00:00 2001 From: panikon Date: Sat, 12 Apr 2014 04:56:52 -0300 Subject: Added sanity checks in itemboundretrieve_sub --- src/char/int_storage.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/char/int_storage.c b/src/char/int_storage.c index 8c49c038d..966e61bb3 100644 --- a/src/char/int_storage.c +++ b/src/char/int_storage.c @@ -316,8 +316,17 @@ int mapif_parse_ItemBoundRetrieve_sub(int fd) StrBuf->Printf(&buf, " `id`=%d",items[j].id); if( items[j].bound && items[j].equip ) { - bound_item[bound_qt] = items[j].equip; - bound_qt++; + // Only the items that are also stored in `char` `equip` + if( items[j].equip&EQP_HAND_R + || items[j].equip&EQP_HAND_L + || items[j].equip&EQP_HEAD_TOP + || items[j].equip&EQP_HEAD_MID + || items[j].equip&EQP_HEAD_LOW + || items[j].equip&EQP_GARMENT + ) { + bound_item[bound_qt] = items[j].equip; + bound_qt++; + } } } -- cgit v1.2.3-60-g2f50