Do not allow paste into panes which have exited, from Romain Francoise

in GitHub issue 3830.
This commit is contained in:
nicm
2024-02-13 08:03:50 +00:00
parent 428f8a9b28
commit 4bdb855020
4 changed files with 13 additions and 1 deletions

View File

@@ -55,6 +55,11 @@ cmd_paste_buffer_exec(struct cmd *self, struct cmdq_item *item)
size_t seplen, bufsize;
int bracket = args_has(args, 'p');
if (window_pane_exited(wp)) {
cmdq_error(item, "target pane has exited");
return (CMD_RETURN_ERROR);
}
bufname = NULL;
if (args_has(args, 'b'))
bufname = args_get(args, 'b');