wgengine/router: use iptablesRunner when no firewall tool is available:

The current router errors out when neither iptables nor nftables support is present. We
should fall back to the previous behaviour which we creates a dummy iptablesRunner.

Fixes: #8878
Signed-off-by: KevinLiang10 <kevinliang@tailscale.com>
This commit is contained in:
KevinLiang10
2023-08-14 20:10:49 +00:00
committed by KevinLiang10
parent 12238dab48
commit 411e3364a9
2 changed files with 15 additions and 15 deletions

View File

@@ -1116,7 +1116,7 @@ func TestChooseFireWallMode(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
got, _ := chooseFireWallMode(t.Logf, tt.det)
got := chooseFireWallMode(t.Logf, tt.det)
if got != tt.want {
t.Errorf("chooseFireWallMode() = %v, want %v", got, tt.want)
}