Don't return immediately on non-Windows system if netprobe_timout is -1

Fixes #1016
This commit is contained in:
Frank Denis 2019-11-04 17:14:31 +01:00
parent 9852a289f8
commit 316c5ca6b1
1 changed files with 1 additions and 1 deletions

View File

@ -10,7 +10,7 @@ import (
)
func NetProbe(address string, timeout int) error {
if len(address) <= 0 || timeout <= 0 {
if len(address) <= 0 || timeout == 0 {
return nil
}
remoteUDPAddr, err := net.ResolveUDPAddr("udp", address)