Comment by toast0

Comment by toast0 14 hours ago

0 replies

You can get tcp measured round trip time from tcp_info with

   struct tcp_info info;
   socklen_t len = sizeof(info);
   getsockopt(sock, IPPROTO_TCP, TCP_INFO, &info, &len);
tcp_info varies by OS and version, but I think tcpi_rtt is well supported.