Fixed crash (probably in debug mode only): iterator+i+o would

first compute and check iterator+i, and not iterator+(i+o), which
caused a crash.
This commit is contained in:
hiker 2015-12-07 23:54:43 +11:00
parent 27f1828c73
commit e74ef461a4

View File

@ -456,8 +456,8 @@ void ProtocolManager::asynchronousUpdate()
if (result) if (result)
{ {
m_events_to_process.getData() m_events_to_process.getData()
.erase(m_events_to_process.getData().begin()+i+offset, .erase(m_events_to_process.getData().begin()+(i+offset),
m_events_to_process.getData().begin()+i+offset+1); m_events_to_process.getData().begin()+(i+offset+1));
offset --; offset --;
} }
} }