summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--source/PluginManager.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/PluginManager.cpp b/source/PluginManager.cpp
index 8f9b2db70..f25b8ec73 100644
--- a/source/PluginManager.cpp
+++ b/source/PluginManager.cpp
@@ -1018,9 +1018,9 @@ void cPluginManager::RemovePluginCommands(cPlugin * a_Plugin)
{
if (itr->second.m_Plugin == a_Plugin)
{
- CommandMap::iterator NextItr = itr + 1; // Stupid GCC doesn't have a std::map::erase() that would return the next iterator
- m_Commands.erase(itr);
- itr = NextItr;
+ CommandMap::iterator EraseMe = itr; // Stupid GCC doesn't have a std::map::erase() that would return the next iterator
+ ++itr;
+ m_Commands.erase(EraseMe);
}
else
{