mirror of
https://github.com/tmux/tmux.git
synced 2025-01-12 19:39:04 +00:00
Merge branch 'obsd-master'
This commit is contained in:
commit
59d1147469
@ -75,7 +75,7 @@ cmd_break_pane_exec(struct cmd *self, struct cmd_q *cmdq)
|
|||||||
window_lost_pane(w, wp);
|
window_lost_pane(w, wp);
|
||||||
layout_close_pane(wp);
|
layout_close_pane(wp);
|
||||||
|
|
||||||
w = wp->window = window_create1(dst_s->sx, dst_s->sy);
|
w = wp->window = window_create(dst_s->sx, dst_s->sy);
|
||||||
TAILQ_INSERT_HEAD(&w->panes, wp, entry);
|
TAILQ_INSERT_HEAD(&w->panes, wp, entry);
|
||||||
w->active = wp;
|
w->active = wp;
|
||||||
name = default_window_name(w);
|
name = default_window_name(w);
|
||||||
|
@ -348,7 +348,7 @@ session_new(struct session *s, const char *name, int argc, char **argv,
|
|||||||
shell = _PATH_BSHELL;
|
shell = _PATH_BSHELL;
|
||||||
|
|
||||||
hlimit = options_get_number(s->options, "history-limit");
|
hlimit = options_get_number(s->options, "history-limit");
|
||||||
w = window_create(name, argc, argv, path, shell, cwd, env, s->tio,
|
w = window_create_spawn(name, argc, argv, path, shell, cwd, env, s->tio,
|
||||||
s->sx, s->sy, hlimit, cause);
|
s->sx, s->sy, hlimit, cause);
|
||||||
if (w == NULL) {
|
if (w == NULL) {
|
||||||
winlink_remove(&s->windows, wl);
|
winlink_remove(&s->windows, wl);
|
||||||
|
4
tmux.h
4
tmux.h
@ -2063,8 +2063,8 @@ void winlink_stack_remove(struct winlink_stack *, struct winlink *);
|
|||||||
struct window *window_find_by_id_str(const char *);
|
struct window *window_find_by_id_str(const char *);
|
||||||
struct window *window_find_by_id(u_int);
|
struct window *window_find_by_id(u_int);
|
||||||
void window_update_activity(struct window *);
|
void window_update_activity(struct window *);
|
||||||
struct window *window_create1(u_int, u_int);
|
struct window *window_create(u_int, u_int);
|
||||||
struct window *window_create(const char *, int, char **, const char *,
|
struct window *window_create_spawn(const char *, int, char **, const char *,
|
||||||
const char *, const char *, struct environ *,
|
const char *, const char *, struct environ *,
|
||||||
struct termios *, u_int, u_int, u_int, char **);
|
struct termios *, u_int, u_int, u_int, char **);
|
||||||
void window_destroy(struct window *);
|
void window_destroy(struct window *);
|
||||||
|
10
window.c
10
window.c
@ -293,7 +293,7 @@ window_update_activity(struct window *w)
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct window *
|
struct window *
|
||||||
window_create1(u_int sx, u_int sy)
|
window_create(u_int sx, u_int sy)
|
||||||
{
|
{
|
||||||
struct window *w;
|
struct window *w;
|
||||||
|
|
||||||
@ -323,19 +323,19 @@ window_create1(u_int sx, u_int sy)
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct window *
|
struct window *
|
||||||
window_create(const char *name, int argc, char **argv, const char *path,
|
window_create_spawn(const char *name, int argc, char **argv, const char *path,
|
||||||
const char *shell, const char *cwd, struct environ *env,
|
const char *shell, const char *cwd, struct environ *env,
|
||||||
struct termios *tio, u_int sx, u_int sy, u_int hlimit, char **cause)
|
struct termios *tio, u_int sx, u_int sy, u_int hlimit, char **cause)
|
||||||
{
|
{
|
||||||
struct window *w;
|
struct window *w;
|
||||||
struct window_pane *wp;
|
struct window_pane *wp;
|
||||||
|
|
||||||
w = window_create1(sx, sy);
|
w = window_create(sx, sy);
|
||||||
wp = window_add_pane(w, NULL, hlimit);
|
wp = window_add_pane(w, NULL, hlimit);
|
||||||
layout_init(w, wp);
|
layout_init(w, wp);
|
||||||
|
|
||||||
if (window_pane_spawn(wp, argc, argv, path, shell, cwd, env, tio,
|
if (window_pane_spawn(wp, argc, argv, path, shell, cwd,
|
||||||
cause) != 0) {
|
env, tio, cause) != 0) {
|
||||||
window_destroy(w);
|
window_destroy(w);
|
||||||
return (NULL);
|
return (NULL);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user