diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-12-06 16:51:05 +0100 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-12-06 16:51:05 +0100 |
commit | bc8bf541854a79cdd83be20d630451a418797299 (patch) | |
tree | ce782917064184ab1933b1a90ef0c63c67df6180 | |
parent | wg-quick: linux: suppress more warnings on weird kernels (diff) | |
download | wireguard-tools-bc8bf541854a79cdd83be20d630451a418797299.tar.xz wireguard-tools-bc8bf541854a79cdd83be20d630451a418797299.zip |
wg-quick: linux: ignore save warnings for iptables-nft
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
-rwxr-xr-x | src/wg-quick/linux.bash | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wg-quick/linux.bash b/src/wg-quick/linux.bash index 4e1f8ee..9bfeed1 100755 --- a/src/wg-quick/linux.bash +++ b/src/wg-quick/linux.bash @@ -189,7 +189,7 @@ remove_iptables() { [[ $line == "*"* || $line == COMMIT || $line == "-A "*"-m comment --comment \"wg-quick(8) rule for $INTERFACE\""* ]] || continue [[ $line == "-A"* ]] && found=1 printf -v restore '%s%s\n' "$restore" "${line/#-A/-D}" - done < <($iptables-save) + done < <($iptables-save 2>/dev/null) [[ $found -ne 1 ]] || echo -n "$restore" | cmd $iptables-restore -n done } |