mirror of
https://github.com/tmate-io/tmate.git
synced 2025-08-18 09:30:04 +02:00
Sync OpenBSD patchset 305:
When using tmux as a login shell, there is currently no way to specify a shell to be used as a login shell inside tmux, so add a default-shell session option. This sets the shell invoked as a login shell when the default-command option is empty. The default option value is whichever of $SHELL, getpwuid(getuid())'s pw_shell or /bin/sh is valid first. Based on a diff from martynas@, changed by me to be a session option rather than a window option.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* $Id: cmd-respawn-window.c,v 1.20 2009-08-16 18:59:12 tcunha Exp $ */
|
||||
/* $Id: cmd-respawn-window.c,v 1.21 2009-09-02 01:02:44 tcunha Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||
@@ -75,7 +75,8 @@ cmd_respawn_window_exec(struct cmd *self, struct cmd_ctx *ctx)
|
||||
window_destroy_panes(w);
|
||||
TAILQ_INSERT_HEAD(&w->panes, wp, entry);
|
||||
window_pane_resize(wp, w->sx, w->sy);
|
||||
if (window_pane_spawn(wp, data->arg, NULL, &env, &s->tio, &cause) != 0) {
|
||||
if (window_pane_spawn(
|
||||
wp, data->arg, NULL, NULL, &env, &s->tio, &cause) != 0) {
|
||||
ctx->error(ctx, "respawn window failed: %s", cause);
|
||||
xfree(cause);
|
||||
environ_free(&env);
|
||||
|
Reference in New Issue
Block a user