MCPcopy Create free account
hub / github.com/catboost/catboost / HasAllPackets

Function HasAllPackets

library/cpp/netliba/v6/udp_client_server.cpp:564–572  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

562 }
563
564 static bool HasAllPackets(const TUdpInTransfer& res) {
565 if (!res.HasLastPacket)
566 return false;
567 for (int i = res.GetPacketCount() - 1; i >= 0; --i) {
568 if (!res.GetPacket(i))
569 return false;
570 }
571 return true;
572 }
573
574 // grouped acks, first int - packet_id, second int - bit mask for 32 packets preceding packet_id
575 const int SIZEOF_ACK = 8;

Callers 1

RecvCycleMethod · 0.70

Calls 2

GetPacketCountMethod · 0.45
GetPacketMethod · 0.45

Tested by

no test coverage detected