versions: Update golang to 1.10.4

Move to golang version 1.10.4 -- the oldest stable golang release at the
time of writing -- since golang 1.10+ is needed to make namespace
handling safe.

Re-ordered a couple of structs (moved `sync.WaitGroup` fields) to keep
the `maligned` linter happy. Previously:

``
virtcontainers/pkg/mock/cc_proxy_mock.go:24:18⚠️ struct of size 160 could be 152 (maligned)
virtcontainers/monitor.go:15:14⚠️ struct of size 80 could be 72 (maligned)
```

See:

- https://github.com/golang/go/issues/20676
- 2595fe7fb6

Also bumped `languages.golang.meta.newest-version` to golang version
1.11, which is the newest stable release at the time of writing.

Fixes #148.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
This commit is contained in:
James O. D. Hunt
2018-09-18 12:14:42 +01:00
parent 62992f5485
commit 526d55b4af
3 changed files with 6 additions and 4 deletions

View File

@@ -186,9 +186,10 @@ languages:
golang: golang:
description: "Google's 'go' language" description: "Google's 'go' language"
notes: "'version' is the default minimum version used by this project." notes: "'version' is the default minimum version used by this project."
version: "1.9.7" issue: "https://github.com/golang/go/issues/20676"
version: "1.10.4"
meta: meta:
newest-version: "1.10" newest-version: "1.11"
specs: specs:
description: "Details of important specifications" description: "Details of important specifications"

View File

@@ -18,9 +18,9 @@ type monitor struct {
sandbox *Sandbox sandbox *Sandbox
checkInterval time.Duration checkInterval time.Duration
watchers []chan error watchers []chan error
wg sync.WaitGroup
running bool running bool
stopCh chan bool stopCh chan bool
wg sync.WaitGroup
} }
func newMonitor(s *Sandbox) *monitor { func newMonitor(s *Sandbox) *monitor {

View File

@@ -25,7 +25,6 @@ type CCProxyMock struct {
sync.Mutex sync.Mutex
t *testing.T t *testing.T
wg sync.WaitGroup
connectionPath string connectionPath string
// proxy socket // proxy socket
@@ -44,6 +43,8 @@ type CCProxyMock struct {
ShimDisconnected chan bool ShimDisconnected chan bool
StdinReceived chan bool StdinReceived chan bool
wg sync.WaitGroup
stopped bool stopped bool
} }