Avoid using an invalidated iterator

This commit is contained in:
chinhodado committed 2014-03-07 16:43:02 -05:00
1 parent fc650681a1
commit 481250931c
1 file changed
+1 -1
+1 -1
View File
@@ -740,7 +740,7 @@ void SymbolMap::AddLabel(const char* name, u32 address, int moduleIndex) {
auto active = activeLabels.find(address);
if (active != activeLabels.end() && active->second.module == moduleIndex) {
activeLabels.erase(active);
activeLabels.insert(std::make_pair(address, existing->second));
activeLabels.insert(std::make_pair(address, label));
}
}
} else {