summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--ssh.c13
2 files changed, 15 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 188869c3d..17750e92c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -29,6 +29,9 @@
29 - deraadt@cvs.openbsd.org 2004/09/15 18:46:04 29 - deraadt@cvs.openbsd.org 2004/09/15 18:46:04
30 [scp.c] 30 [scp.c]
31 scratch that do { } while (0) wrapper in this case 31 scratch that do { } while (0) wrapper in this case
32 - djm@cvs.openbsd.org 2004/09/23 13:00:04
33 [ssh.c]
34 correctly honour -n in multiplex client mode; spotted by sturm@ ok markus@
32 35
3320041102 3620041102
34 - (dtucker) [configure.ac includes.h] Bug #947: Fix compile error on HP-UX 37 - (dtucker) [configure.ac includes.h] Bug #947: Fix compile error on HP-UX
@@ -1808,4 +1811,4 @@
1808 - (djm) Trim deprecated options from INSTALL. Mention UsePAM 1811 - (djm) Trim deprecated options from INSTALL. Mention UsePAM
1809 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu 1812 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
1810 1813
1811$Id: ChangeLog,v 1.3569 2004/11/05 09:10:02 dtucker Exp $ 1814$Id: ChangeLog,v 1.3570 2004/11/05 09:19:51 dtucker Exp $
diff --git a/ssh.c b/ssh.c
index 7859b0f78..c231c5fae 100644
--- a/ssh.c
+++ b/ssh.c
@@ -40,7 +40,7 @@
40 */ 40 */
41 41
42#include "includes.h" 42#include "includes.h"
43RCSID("$OpenBSD: ssh.c,v 1.227 2004/09/15 00:46:01 deraadt Exp $"); 43RCSID("$OpenBSD: ssh.c,v 1.228 2004/09/23 13:00:04 djm Exp $");
44 44
45#include <openssl/evp.h> 45#include <openssl/evp.h>
46#include <openssl/err.h> 46#include <openssl/err.h>
@@ -1249,11 +1249,20 @@ static void
1249control_client(const char *path) 1249control_client(const char *path)
1250{ 1250{
1251 struct sockaddr_un addr; 1251 struct sockaddr_un addr;
1252 int i, r, sock, exitval, num_env, addr_len; 1252 int i, r, fd, sock, exitval, num_env, addr_len;
1253 Buffer m; 1253 Buffer m;
1254 char *cp; 1254 char *cp;
1255 extern char **environ; 1255 extern char **environ;
1256 1256
1257 if (stdin_null_flag) {
1258 if ((fd = open(_PATH_DEVNULL, O_RDONLY)) == -1)
1259 fatal("open(/dev/null): %s", strerror(errno));
1260 if (dup2(fd, STDIN_FILENO) == -1)
1261 fatal("dup2: %s", strerror(errno));
1262 if (fd > STDERR_FILENO)
1263 close(fd);
1264 }
1265
1257 memset(&addr, '\0', sizeof(addr)); 1266 memset(&addr, '\0', sizeof(addr));
1258 addr.sun_family = AF_UNIX; 1267 addr.sun_family = AF_UNIX;
1259 addr_len = offsetof(struct sockaddr_un, sun_path) + 1268 addr_len = offsetof(struct sockaddr_un, sun_path) +