mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 13:27:17 +01:00
hardening iterator
This commit is contained in:
parent
43939cedf4
commit
8f9874570a
|
@ -203,7 +203,7 @@ namespace client
|
||||||
std::vector<std::shared_ptr<DatagramSessionInfo> > sessions;
|
std::vector<std::shared_ptr<DatagramSessionInfo> > sessions;
|
||||||
std::lock_guard<std::mutex> lock (m_SessionsMutex);
|
std::lock_guard<std::mutex> lock (m_SessionsMutex);
|
||||||
|
|
||||||
for (auto it: m_Sessions)
|
for (const auto &it: m_Sessions)
|
||||||
{
|
{
|
||||||
auto s = it.second;
|
auto s = it.second;
|
||||||
if (!s->m_Destination) continue;
|
if (!s->m_Destination) continue;
|
||||||
|
|
Loading…
Reference in a new issue