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

Method TTcpFastOpenFeature

util/network/socket.cpp:465–472  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

463#if defined(TCP_FASTOPEN)
464 struct TTcpFastOpenFeature {
465 inline TTcpFastOpenFeature()
466 : HasFastOpen_(false)
467 {
468 TSocketHolder tmp(socket(AF_INET, SOCK_STREAM, 0));
469 int val = 1;
470 int ret = SetSockOpt(tmp, IPPROTO_TCP, TCP_FASTOPEN, val);
471 HasFastOpen_ = (ret == 0);
472 }
473
474 inline void SetFastOpen(SOCKET s, int qlen) const {
475 if (HasFastOpen_) {

Callers

nothing calls this directly

Calls 1

SetSockOptFunction · 0.85

Tested by

no test coverage detected