Skip to content

Fix "connect: network is unreachable"

Compare
Choose a tag to compare
@xtaci xtaci released this 19 Sep 02:54
· 555 commits to master since this release

Fix the problem below:

2016/09/18 20:21:21 dial udp **********:80: connect: network is unreachable
net.DialUDP
github.com/xtaci/kcp-go.DialWithOptions
    /Users/xtaci/.godeps/src/github.com/xtaci/kcp-go/sess.go:832
main.main.func1.1
...

addressed by waiting until a connection is created.

$ go version
go version go1.7.1 darwin/amd64
09aea30
xtaci/kcp-go@1fb16b3
xtaci/smux@bc68dab

MD5 (kcptun-linux-amd64-20160919.tar.gz) = 37323b632184240bd7f0d2c319524686
MD5 (kcptun-linux-386-20160919.tar.gz) = e16da92bd14041609cbf8b2385198ce9
MD5 (kcptun-darwin-amd64-20160919.tar.gz) = c5b65645f7e53e3943fb62e946fe1aea
MD5 (kcptun-darwin-386-20160919.tar.gz) = 3473b32f8ceaaf3923204a439c5a2826
MD5 (kcptun-windows-amd64-20160919.tar.gz) = 16f8201310fa5f09fbe2333f09942146
MD5 (kcptun-windows-386-20160919.tar.gz) = 734d57fc138313118625e70cdd71324f
MD5 (kcptun-freebsd-amd64-20160919.tar.gz) = a27726e60f0dc53393855dedc2c8d4db
MD5 (kcptun-freebsd-386-20160919.tar.gz) = 5ff7d5b57974a752b92e11722cdd6281
MD5 (kcptun-linux-arm-20160919.tar.gz) = b66faa598612df499580cfdfd0a36d3d