mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-13 20:58:29 +00:00
Put a limit on the multicast TX queue to prevent memory use ridiculousness.
This commit is contained in:
@ -275,6 +275,11 @@ void Multicaster::send(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
if (gs.txQueue.size() >= ZT_TX_QUEUE_SIZE) {
|
||||||
|
RR->t->outgoingNetworkFrameDropped(tPtr,network,src,mg.mac(),etherType,0,len,"multicast TX queue is full");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const unsigned int gatherLimit = (limit - (unsigned int)gs.members.size()) + 1;
|
const unsigned int gatherLimit = (limit - (unsigned int)gs.members.size()) + 1;
|
||||||
|
|
||||||
if ((gs.members.empty())||((now - gs.lastExplicitGather) >= ZT_MULTICAST_EXPLICIT_GATHER_DELAY)) {
|
if ((gs.members.empty())||((now - gs.lastExplicitGather) >= ZT_MULTICAST_EXPLICIT_GATHER_DELAY)) {
|
||||||
|
Reference in New Issue
Block a user