Fix iterating
This commit is contained in:
parent
9ebbe969c8
commit
ffbe5f6a2f
@ -226,9 +226,7 @@ void cChunkSender::SendChunk(int a_ChunkX, int a_ChunkZ, std::unordered_set<cCli
|
|||||||
{
|
{
|
||||||
if (!(*itr)->WantsSendChunk(a_ChunkX, a_ChunkZ))
|
if (!(*itr)->WantsSendChunk(a_ChunkX, a_ChunkZ))
|
||||||
{
|
{
|
||||||
auto toremove = itr;
|
itr = a_Clients.erase(itr);
|
||||||
itr++;
|
|
||||||
a_Clients.erase(toremove);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user