Show retransmit count for FreeBSD too. This may not actually
be implemented by the OS yet - the struct member starting with a double underscore indicates that it's not fully implemented.
This commit is contained in:
parent
0d48915c69
commit
874856ab6b
@ -55,9 +55,13 @@ has_tcpinfo_retransmits(void)
|
|||||||
{
|
{
|
||||||
#if defined(linux)
|
#if defined(linux)
|
||||||
return 1;
|
return 1;
|
||||||
|
#else
|
||||||
|
#if defined(__FreeBSD__) && __FreeBSD_version >= 600000
|
||||||
|
return 1;
|
||||||
#else
|
#else
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*************************************************************/
|
/*************************************************************/
|
||||||
@ -79,9 +83,13 @@ get_tcpinfo_retransmits(struct iperf_interval_results *irp)
|
|||||||
{
|
{
|
||||||
#if defined(linux)
|
#if defined(linux)
|
||||||
return irp->tcpInfo.tcpi_retransmits;
|
return irp->tcpInfo.tcpi_retransmits;
|
||||||
|
#else
|
||||||
|
#if defined(__FreeBSD__) && __FreeBSD_version >= 600000
|
||||||
|
return irp->tcpInfo.__tcpi_retransmits;
|
||||||
#else
|
#else
|
||||||
return -1;
|
return -1;
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*************************************************************/
|
/*************************************************************/
|
||||||
|
Loading…
Reference in New Issue
Block a user