aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorsapier <Sapier at GMX dot net>2015-01-17 19:14:36 +0100
committersapier <Sapier at GMX dot net>2015-01-17 19:14:36 +0100
commita39c136e69b53c4f14d6ddb6d5a2bebc23dc9cbe (patch)
treebc4dbe9d7a18a70eb96ddbd59c8269cfd5be9c5b /src
parent2959d6b3dac587e0843b8791a30d8c31e78d58b4 (diff)
downloadminetest-a39c136e69b53c4f14d6ddb6d5a2bebc23dc9cbe.tar.gz
minetest-a39c136e69b53c4f14d6ddb6d5a2bebc23dc9cbe.tar.bz2
minetest-a39c136e69b53c4f14d6ddb6d5a2bebc23dc9cbe.zip
Fix NodeMetadataList loosing memory on deserialize due to invalid clear map call instead of clear
Diffstat (limited to 'src')
-rw-r--r--src/nodemetadata.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nodemetadata.cpp b/src/nodemetadata.cpp
index b8c7d3d9c..1e40a1630 100644
--- a/src/nodemetadata.cpp
+++ b/src/nodemetadata.cpp
@@ -109,10 +109,10 @@ void NodeMetadataList::serialize(std::ostream &os) const
void NodeMetadataList::deSerialize(std::istream &is, IGameDef *gamedef)
{
- m_data.clear();
+ clear();
u8 version = readU8(is);
-
+
if(version == 0){
// Nothing
return;