diff options
author | 2025-05-05 15:13:06 +0800 | |
---|---|---|
committer | 2025-05-21 00:16:18 +0200 | |
commit | a2dbc3377e0f16f57f856e696162da62ab5b3766 (patch) | |
tree | 3bbbb0b0c2a25f037b8b5a103798efa82db99c97 | |
parent | ipc: add stub for allowedips flags on other platforms (diff) | |
download | wireguard-tools-a2dbc3377e0f16f57f856e696162da62ab5b3766.tar.xz wireguard-tools-a2dbc3377e0f16f57f856e696162da62ab5b3766.zip |
wg-quick: linux: add 'dev' to 'ip link add' to avoid keyword conflicts
Signed-off-by: TriangleSnake <trianglesnake2002@gmail.com>
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 4193ce5..93df80d 100755 --- a/src/wg-quick/linux.bash +++ b/src/wg-quick/linux.bash @@ -87,7 +87,7 @@ auto_su() { add_if() { local ret - if ! cmd ip link add "$INTERFACE" type wireguard; then + if ! cmd ip link add dev "$INTERFACE" type wireguard; then ret=$? [[ -e /sys/module/wireguard ]] || ! command -v "${WG_QUICK_USERSPACE_IMPLEMENTATION:-wireguard-go}" >/dev/null && exit $ret echo "[!] Missing WireGuard kernel module. Falling back to slow userspace implementation." >&2 |