summaryrefslogtreecommitdiff
path: root/sshconnect.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2010-10-07 22:07:11 +1100
committerDamien Miller <djm@mindrot.org>2010-10-07 22:07:11 +1100
commit38d9a965bfc795fba1c000e0b42e705e2bcd34c9 (patch)
treed21fcf058b9c991de5c08ef4df8e0a548963765c /sshconnect.c
parent9a3d0dc062e4ebcafdc399ed8522df97066b139e (diff)
- djm@cvs.openbsd.org 2010/10/05 05:13:18
[sftp.c sshconnect.c] use default shell /bin/sh if $SHELL is ""; ok markus@
Diffstat (limited to 'sshconnect.c')
-rw-r--r--sshconnect.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sshconnect.c b/sshconnect.c
index 4d3a08551..6d2f1341c 100644
--- a/sshconnect.c
+++ b/sshconnect.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sshconnect.c,v 1.225 2010/08/31 11:54:45 djm Exp $ */ 1/* $OpenBSD: sshconnect.c,v 1.226 2010/10/05 05:13:18 djm Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -87,7 +87,7 @@ ssh_proxy_connect(const char *host, u_short port, const char *proxy_command)
87 pid_t pid; 87 pid_t pid;
88 char *shell, strport[NI_MAXSERV]; 88 char *shell, strport[NI_MAXSERV];
89 89
90 if ((shell = getenv("SHELL")) == NULL) 90 if ((shell = getenv("SHELL")) == NULL || *shell == '\0')
91 shell = _PATH_BSHELL; 91 shell = _PATH_BSHELL;
92 92
93 /* Convert the port number into a string. */ 93 /* Convert the port number into a string. */
@@ -1237,7 +1237,7 @@ ssh_local_cmd(const char *args)
1237 args == NULL || !*args) 1237 args == NULL || !*args)
1238 return (1); 1238 return (1);
1239 1239
1240 if ((shell = getenv("SHELL")) == NULL) 1240 if ((shell = getenv("SHELL")) == NULL || *shell == '\0')
1241 shell = _PATH_BSHELL; 1241 shell = _PATH_BSHELL;
1242 1242
1243 pid = fork(); 1243 pid = fork();