OSDN Git Service

Reduce get external IP waiting time
authorYahtoo Ma <yahtoo.ma@gmail.com>
Thu, 10 May 2018 01:40:11 +0000 (09:40 +0800)
committerYahtoo Ma <yahtoo.ma@gmail.com>
Thu, 10 May 2018 01:40:11 +0000 (09:40 +0800)
p2p/public_ip.go

index 81fc76d..b8b9603 100644 (file)
@@ -25,7 +25,7 @@ type IpResult struct {
        Ip      string
 }
 
-var timeout = time.Duration(10)
+var timeout = time.Duration(5)
 
 func GetIP() *IpResult {
        resultCh := make(chan *IpResult, 1)