diff options
Diffstat (limited to 'lib/exec_shell.c')
| -rw-r--r-- | lib/exec_shell.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/exec_shell.c b/lib/exec_shell.c index ffe65f006e..8f10ea4df4 100644 --- a/lib/exec_shell.c +++ b/lib/exec_shell.c @@ -26,19 +26,15 @@ #include "xalloc.h" #include "exec_shell.h" - -#define DEFAULT_SHELL "/bin/sh" +#include "shells.h" void __attribute__((__noreturn__)) exec_shell(void) { - const char *shell = getenv("SHELL"); + const char *shell = ul_default_shell(0, NULL); char *shellc; const char *shell_basename; char *arg0; - if (!shell) - shell = DEFAULT_SHELL; - shellc = xstrdup(shell); shell_basename = basename(shellc); xasprintf(&arg0, "-%s", shell_basename); |
