point-source / dart_ping

Multi-platform network ping utility for Dart
30 stars 13 forks source link

Timeout description does not contain time unit of measure #19

Closed guyluz11 closed 2 years ago

guyluz11 commented 2 years ago

Timeout description does not contain time unit of measure in ping_interface.dart page

https://github.com/point-source/dart_ping/blob/9a0036973c643d42e03736494e74a4e469af14e6/dart_ping/lib/src/ping_interface.dart#L26

After checking it on the Linux implementation

https://github.com/point-source/dart_ping/blob/9a0036973c643d42e03736494e74a4e469af14e6/dart_ping/lib/src/ping/linux_ping.dart#L32

I have found that the -W for ping command on Linux is in seconds

-W timeout Time to wait for a response, in seconds. The option affects only timeout in absence of any responses, otherwise ping waits for two RTTs. Real number allowed with dot as a decimal separator (regardless locale setup). 0 means infinite timeout.

I think adding this to our description is important, or change timeout to timeoutInSeconds.