diff options
author | nicm <nicm> | 2020-03-17 11:10:12 +0000 |
---|---|---|
committer | nicm <nicm> | 2020-03-17 11:10:12 +0000 |
commit | 115bb33257ece9eec1c890cc04683227678a895f (patch) | |
tree | 0352f5aa8363bd3f98f9c6f2f94d0354c85a88d0 /tmux.c | |
parent | fb396286ff8330f35eae54f47b7f233839a23e6f (diff) | |
download | rtmux-115bb33257ece9eec1c890cc04683227678a895f.tar.gz rtmux-115bb33257ece9eec1c890cc04683227678a895f.tar.bz2 rtmux-115bb33257ece9eec1c890cc04683227678a895f.zip |
Ignore default-shell (and use /bin/sh) if it invalid not just if it is
tmux itself, also refuse to set the option to something invalid in the
first place. GitHub issue 2120.
Diffstat (limited to 'tmux.c')
-rw-r--r-- | tmux.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -49,8 +49,8 @@ const char *shell_command; static __dead void usage(void); static char *make_label(const char *, char **); +static int areshell(const char *); static const char *getshell(void); -static int checkshell(const char *); static __dead void usage(void) @@ -79,7 +79,7 @@ getshell(void) return (_PATH_BSHELL); } -static int +int checkshell(const char *shell) { if (shell == NULL || *shell != '/') @@ -91,7 +91,7 @@ checkshell(const char *shell) return (1); } -int +static int areshell(const char *shell) { const char *progname, *ptr; |