Do not crash with pane_current_command if the pane is newly created and

has no shell set, from Thomas Adam.
pull/1944/head
nicm 2019-10-14 09:24:06 +00:00
parent f18cd5b19c
commit b598bbcc2e
1 changed files with 1 additions and 1 deletions

View File

@ -574,7 +574,7 @@ format_cb_current_command(struct format_tree *ft, struct format_entry *fe)
struct window_pane *wp = ft->wp;
char *cmd;
if (wp == NULL)
if (wp == NULL || wp->shell == NULL)
return;
cmd = get_proc_name(wp->fd, wp->tty);