net: fix looking up port numbers starting with numbers.
LookupPort() correctly parses service names beginning with numerals by implementing a new parser, mainly taken from strconv/atoi.go. Also testes some previously undefined behaviours around port numbers larger than 65535 that previously could lead to some tests fail with EOPNOTSUPP (Operation Not Supported). Fixes #14322 Change-Id: I1b90dbed434494723e261d84e73fe705e5c0507a Reviewed-on: https://go-review.googlesource.com/19720 Run-TryBot: Mikio Hara <mikioh.mikioh@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Mikio Hara <mikioh.mikioh@gmail.com>
Showing
src/net/port.go
0 → 100644
src/net/port_test.go
0 → 100644
Please register or sign in to comment