net, internal/poll: reset value before adding in minor kernel version

Fixes #42733

Change-Id: I5446aeb5de13cd70212755fb12c9bc484f343c74
Reviewed-on: https://go-review.googlesource.com/c/go/+/271846
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
This commit is contained in:
Ian Lance Taylor 2020-11-19 19:15:57 -08:00
parent 0dcc7d6ea8
commit 66c0264506
2 changed files with 2 additions and 0 deletions

View file

@ -35,6 +35,7 @@ func kernelVersion() (major int, minor int) {
if vi >= len(values) {
break
}
value = 0
}
}
switch vi {

View file

@ -27,6 +27,7 @@ func kernelVersion() (major int, minor int) {
if vi >= len(values) {
break
}
value = 0
}
}
switch vi {