mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-03-22 00:59:08 +01:00
drop earlier if delayed queue is semi-full
This commit is contained in:
parent
96cf6ca531
commit
8f28cee32f
1 changed files with 4 additions and 1 deletions
|
@ -477,6 +477,9 @@ namespace transport
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (auto& it1: msgs)
|
for (auto& it1: msgs)
|
||||||
|
if (sz > MAX_NUM_DELAYED_MESSAGES/2 && it1->onDrop)
|
||||||
|
it1->Drop (); // drop earlier because we can handle it
|
||||||
|
else
|
||||||
it->second.delayedMessages.push_back (it1);
|
it->second.delayedMessages.push_back (it1);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Reference in a new issue