summaryrefslogtreecommitdiff
path: root/src/map/map.c
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2014-01-12 13:27:53 -0200
committershennetsind <ind@henn.et>2014-01-12 13:27:53 -0200
commit209d15e07d52a52c110b01f4bad0b52080a69550 (patch)
tree25323e678f26f09143b7c3c486f5f81ac6379e7f /src/map/map.c
parent95f13f3420822111f928ba6079fbc2061bd38c5f (diff)
downloadhercules-209d15e07d52a52c110b01f4bad0b52080a69550.tar.gz
hercules-209d15e07d52a52c110b01f4bad0b52080a69550.tar.bz2
hercules-209d15e07d52a52c110b01f4bad0b52080a69550.tar.xz
hercules-209d15e07d52a52c110b01f4bad0b52080a69550.zip
Fixed ERS Cache sharing
Enforcing cache to match the option condition in order for it to be shared. Special Thanks to Haruna! Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/map.c')
-rw-r--r--src/map/map.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/map/map.c b/src/map/map.c
index 922807158..68a675a37 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -5558,9 +5558,10 @@ int do_init(int argc, char *argv[])
map->iwall_db = strdb_alloc(DB_OPT_RELEASE_DATA,2*NAME_LENGTH+2+1); // [Zephyrus] Invisible Walls
map->zone_db = strdb_alloc(DB_OPT_DUP_KEY|DB_OPT_RELEASE_DATA, MAP_ZONE_NAME_LENGTH);
- map->iterator_ers = ers_new(sizeof(struct s_mapiterator),"map.c::map_iterator_ers",ERS_OPT_CLEAN);
-
- map->flooritem_ers = ers_new(sizeof(struct flooritem_data),"map.c::map_flooritem_ers",ERS_OPT_CLEAN);
+ map->iterator_ers = ers_new(sizeof(struct s_mapiterator),"map.c::map_iterator_ers",ERS_OPT_CLEAN|ERS_OPT_FLEX_CHUNK);
+ ers_chunk_size(map->iterator_ers, 25);
+
+ map->flooritem_ers = ers_new(sizeof(struct flooritem_data),"map.c::map_flooritem_ers",ERS_OPT_CLEAN|ERS_OPT_FLEX_CHUNK);
ers_chunk_size(map->flooritem_ers, 100);
if (!minimal) {