diff options
author | shennetsind <ind@henn.et> | 2014-02-02 16:50:03 -0200 |
---|---|---|
committer | shennetsind <ind@henn.et> | 2014-02-02 16:50:03 -0200 |
commit | 00ef66fb9261a50e6761cf77c11e7f468494c95f (patch) | |
tree | c1bc879e76ecaaf619366d6392c13a72bb5640b9 /src/map/unit.c | |
parent | d33469689ea8e671fa0d525d54bce6932dfe9107 (diff) | |
download | hercules-00ef66fb9261a50e6761cf77c11e7f468494c95f.tar.gz hercules-00ef66fb9261a50e6761cf77c11e7f468494c95f.tar.bz2 hercules-00ef66fb9261a50e6761cf77c11e7f468494c95f.tar.xz hercules-00ef66fb9261a50e6761cf77c11e7f468494c95f.zip |
Fixed item combo bypassing disabled item restrictions
Special Thanks to Mhalicot!
Also improves the overall memory usage of the item combo feature
Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/unit.c')
-rw-r--r-- | src/map/unit.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/map/unit.c b/src/map/unit.c index 7b37be266..320649a6c 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -2363,11 +2363,11 @@ int unit_free(struct block_list *bl, clr_type clrtype) { sd->st = NULL; sd->npc_id = 0; } - if( sd->combos.count ) { - aFree(sd->combos.bonus); - aFree(sd->combos.id); - sd->combos.count = 0; + if( sd->combos ) { + aFree(sd->combos); + sd->combos = NULL; } + sd->combo_count = 0; /* [Ind/Hercules] */ if( sd->sc_display_count ) { for(i = 0; i < sd->sc_display_count; i++) { |