aboutsummaryrefslogtreecommitdiffstats
path: root/executor
diff options
context:
space:
mode:
authorGreg Steuck <blackgnezdo@gmail.com>2021-09-02 14:47:10 +0200
committerGitHub <noreply@github.com>2021-09-02 14:47:10 +0200
commitf62a58290e2f1200a2b21f2707a9ff0394a2a724 (patch)
tree0d768a0752e458cb9728f0a8ae1fe189842148b5 /executor
parent15cea0a381c6ef9a7b4ffb2770360ce8882274c5 (diff)
executor: ifconfig destroy wants the interface (not device) name (#2739)
At least on OpenBSD this is the behavior: % doas ifconfig tun5 create % doas ifconfig tun5 destroy % doas ifconfig tun5 create % doas ifconfig /dev/tun5 destroy ifconfig: SIOCIFDESTROY: Invalid argument
Diffstat (limited to 'executor')
-rw-r--r--executor/common_bsd.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/executor/common_bsd.h b/executor/common_bsd.h
index 131ab0764..d250c5f29 100644
--- a/executor/common_bsd.h
+++ b/executor/common_bsd.h
@@ -209,7 +209,7 @@ static void initialize_tun(int tun_id)
execute_command(0, "ifconfig %s destroy", tun_iface);
execute_command(0, "ifconfig %s create", tun_iface);
#else
- execute_command(0, "ifconfig %s destroy", tun_device);
+ execute_command(0, "ifconfig %s destroy", tun_iface);
#endif
tunfd = open(tun_device, O_RDWR | O_NONBLOCK);