Skip to content
Discussion options

You must be logged in to vote

Hi,

Is transit the one-way latency?

Yes, but only if the timers of the client and the server are fully synchronized. Note that the code you found is for estimating the jitter (see the code that follows these lines), where the variance of the latency is important, not the latency itself.

Additionally, how can I do this for TCP?

tcp_info may help. You can get it using getsockopt(..., IPPROTO_TCP, TCP_INFO, ...) (see for example the iperf3 tcp_info.c file). However, it seems that it only calculates RTT, but maybe by dividing it by 2 you can get an approximate one-way latency.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by choiyhking
Comment options

You must be logged in to vote
1 reply
@bmah888
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants