summaryrefslogtreecommitdiff
path: root/src/emap/craft.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-03 01:15:02 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-04 16:29:02 +0300
commit1246fcc42bc44f624a1c8bd855fd1dd82d51f228 (patch)
tree5ad659704c2f57711dc77e184e4110b527e12e79 /src/emap/craft.c
parent9b47893aa8736d173ca85a30c5336d9418b3044f (diff)
downloadevol-hercules-1246fcc42bc44f624a1c8bd855fd1dd82d51f228.tar.gz
evol-hercules-1246fcc42bc44f624a1c8bd855fd1dd82d51f228.tar.bz2
evol-hercules-1246fcc42bc44f624a1c8bd855fd1dd82d51f228.tar.xz
evol-hercules-1246fcc42bc44f624a1c8bd855fd1dd82d51f228.zip
Reduce memory usage in vectors.evolrelease2016-08-07
Diffstat (limited to 'src/emap/craft.c')
-rw-r--r--src/emap/craft.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/emap/craft.c b/src/emap/craft.c
index c33ec64..f9f6f54 100644
--- a/src/emap/craft.c
+++ b/src/emap/craft.c
@@ -205,7 +205,7 @@ struct craft_vardata *craft_str_to_craft(const char *craftstr)
strutil_free(craftdata);
return false;
}
- VECTOR_ENSURE(crslot->items, slot + 1, 1);
+ VECTOR_ENSURE(crslot->items, 1, 1);
VECTOR_INSERTZEROED(crslot->items, slot);
struct item_pair *pair = &VECTOR_INDEX(crslot->items, slot);
pair->index = index;