diff options
author | Colin Watson <cjwatson@debian.org> | 2010-08-23 23:52:36 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2010-08-23 23:52:36 +0100 |
commit | 78799892cb1858927be02be9737c594052e3f910 (patch) | |
tree | ac3dc2e848ab9dc62fe4252e01e52c3d456f628f /openbsd-compat/port-tun.c | |
parent | 3875951bb76a9ec62634ae4026c9cc885d933477 (diff) | |
parent | 31e30b835fd9695d3b6647cab4867001b092e28f (diff) |
* New upstream release (http://www.openssh.com/txt/release-5.6):
- Added a ControlPersist option to ssh_config(5) that automatically
starts a background ssh(1) multiplex master when connecting. This
connection can stay alive indefinitely, or can be set to automatically
close after a user-specified duration of inactivity (closes: #335697,
#350898, #454787, #500573, #550262).
- Support AuthorizedKeysFile, AuthorizedPrincipalsFile,
HostbasedUsesNameFromPacketOnly, and PermitTunnel in sshd_config(5)
Match blocks (closes: #549858).
- sftp(1): fix ls in working directories that contain globbing
characters in their pathnames (LP: #530714).
Diffstat (limited to 'openbsd-compat/port-tun.c')
-rw-r--r-- | openbsd-compat/port-tun.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/openbsd-compat/port-tun.c b/openbsd-compat/port-tun.c index ddc92d0f3..0d756f74f 100644 --- a/openbsd-compat/port-tun.c +++ b/openbsd-compat/port-tun.c | |||
@@ -173,9 +173,11 @@ sys_tun_open(int tun, int mode) | |||
173 | 173 | ||
174 | if (ioctl(sock, SIOCGIFFLAGS, &ifr) == -1) | 174 | if (ioctl(sock, SIOCGIFFLAGS, &ifr) == -1) |
175 | goto failed; | 175 | goto failed; |
176 | ifr.ifr_flags |= IFF_UP; | 176 | if ((ifr.ifr_flags & IFF_UP) == 0) { |
177 | if (ioctl(sock, SIOCSIFFLAGS, &ifr) == -1) | 177 | ifr.ifr_flags |= IFF_UP; |
178 | goto failed; | 178 | if (ioctl(sock, SIOCSIFFLAGS, &ifr) == -1) |
179 | goto failed; | ||
180 | } | ||
179 | 181 | ||
180 | close(sock); | 182 | close(sock); |
181 | return (fd); | 183 | return (fd); |