mirror of
https://github.com/tailscale/tailscale.git
synced 2024-11-26 19:45:35 +00:00
88cc0ad9f7
The util/linuxfw/iptables.go had a bunch of code that wasn't yet used (in prep for future work) but because of its imports, ended up initializing code deep within gvisor that panicked on init on arm64 systems not using 4KB pages. This deletes the unused code to delete the imports and remove the panic. We can then cherry-pick this back to the branch and restore it later in a different way. A new test makes sure we don't regress in the future by depending on the panicking package in question. Fixes #8658 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
35 lines
907 B
Go
35 lines
907 B
Go
// Copyright (c) Tailscale Inc & AUTHORS
|
|
// SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
package main // import "tailscale.com/cmd/tailscaled"
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"tailscale.com/tstest/deptest"
|
|
)
|
|
|
|
func TestNothing(t *testing.T) {
|
|
// This test does nothing on purpose, so we can run
|
|
// GODEBUG=memprofilerate=1 go test -v -run=Nothing -memprofile=prof.mem
|
|
// without any errors about no matching tests.
|
|
}
|
|
|
|
func TestDeps(t *testing.T) {
|
|
deptest.DepChecker{
|
|
GOOS: "darwin",
|
|
GOARCH: "arm64",
|
|
BadDeps: map[string]string{
|
|
"gvisor.dev/gvisor/pkg/hostarch": "will crash on non-4K page sizes; see https://github.com/tailscale/tailscale/issues/8658",
|
|
},
|
|
}.Check(t)
|
|
|
|
deptest.DepChecker{
|
|
GOOS: "linux",
|
|
GOARCH: "arm64",
|
|
BadDeps: map[string]string{
|
|
"gvisor.dev/gvisor/pkg/hostarch": "will crash on non-4K page sizes; see https://github.com/tailscale/tailscale/issues/8658",
|
|
},
|
|
}.Check(t)
|
|
}
|