summaryrefslogtreecommitdiff
path: root/library
diff options
context:
space:
mode:
Diffstat (limited to 'library')
-rw-r--r--library/modules/World.cpp6
m---------library/xml0
2 files changed, 5 insertions, 1 deletions
diff --git a/library/modules/World.cpp b/library/modules/World.cpp
index e14aa02a..67b8c123 100644
--- a/library/modules/World.cpp
+++ b/library/modules/World.cpp
@@ -300,6 +300,8 @@ PersistentDataItem World::GetPersistentData(const std::string &key, bool *added)
void World::GetPersistentData(std::vector<PersistentDataItem> *vec, const std::string &key, bool prefix)
{
+ vec->clear();
+
if (!BuildPersistentCache())
return;
@@ -343,8 +345,10 @@ bool World::DeletePersistentData(const PersistentDataItem &item)
auto eqrange = d->persistent_index.equal_range(item.key_value);
- for (auto it = eqrange.first; it != eqrange.second; ++it)
+ for (auto it2 = eqrange.first; it2 != eqrange.second; )
{
+ auto it = it2; ++it2;
+
if (it->second != -item.id)
continue;
diff --git a/library/xml b/library/xml
-Subproject d55f1cf43dd71d3abee724bfa88a0a401b4ccaa
+Subproject 2bc8fbdf71143398817d31e06e169a01cce37c5