[openssh-commits] [openssh] 01/01: include tunnel device path in error message
git+noreply at mindrot.org
git+noreply at mindrot.org
Sat Jan 25 16:30:54 AEDT 2020
This is an automated email from the git hooks/post-receive script.
djm pushed a commit to branch master
in repository openssh.
commit e1e97cae19ff07b7a7f7e82556bc048c3c54af63
Author: Damien Miller <djm at mindrot.org>
Date: Sat Jan 25 16:30:22 2020 +1100
include tunnel device path in error message
---
openbsd-compat/port-net.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/openbsd-compat/port-net.c b/openbsd-compat/port-net.c
index bb535626..617bffce 100644
--- a/openbsd-compat/port-net.c
+++ b/openbsd-compat/port-net.c
@@ -137,6 +137,7 @@ sys_set_process_rdomain(const char *name)
#if defined(SSH_TUN_LINUX)
#include <linux/if_tun.h>
+#define TUN_CTRL_DEV "/dev/net/tun"
int
sys_tun_open(int tun, int mode, char **ifname)
@@ -147,10 +148,9 @@ sys_tun_open(int tun, int mode, char **ifname)
if (ifname != NULL)
*ifname = NULL;
-
- if ((fd = open("/dev/net/tun", O_RDWR)) == -1) {
- debug("%s: failed to open tunnel control interface: %s",
- __func__, strerror(errno));
+ if ((fd = open(TUN_CTRL_DEV, O_RDWR)) == -1) {
+ debug("%s: failed to open tunnel control device \"%s\": %s",
+ __func__, TUN_CTRL_DEV, strerror(errno));
return (-1);
}
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list