1
0
mirror of https://github.com/tmux/tmux.git synced 2025-04-28 08:08:54 +00:00
This commit is contained in:
holio0 2025-03-29 08:44:06 +05:30 committed by GitHub
commit bdf4f5ae16
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 17 additions and 2 deletions

View File

@ -479,6 +479,14 @@ const struct options_table_entry options_table[] = {
"'User0', 'User1' and so on." "'User0', 'User1' and so on."
}, },
{ .name = "forward-unrequested-escseq",
.type = OPTIONS_TABLE_FLAG,
.scope = OPTIONS_TABLE_SERVER,
.default_num = 0,
.text = "Whether unrequested escape sequences are forwarded to "
"clients. Can be 'off' (disallowed) or 'on' (allowed)."
},
/* Session options. */ /* Session options. */
{ .name = "activity-action", { .name = "activity-action",
.type = OPTIONS_TABLE_CHOICE, .type = OPTIONS_TABLE_CHOICE,

5
tmux.1
View File

@ -4612,6 +4612,11 @@ This respects the
.Ic base-index .Ic base-index
option if it has been set. option if it has been set.
If off, do not renumber the windows. If off, do not renumber the windows.
.It Xo Ic forward-unrequested-escseq
.Op Ic on | off
.Xc
If on, when an unrequested escape sequence is received, tmux will forward it to client.
If off, tmux will ignore it.
.It Ic repeat-time Ar time .It Ic repeat-time Ar time
Allow multiple commands to be entered without pressing the prefix key again Allow multiple commands to be entered without pressing the prefix key again
in the specified in the specified

View File

@ -1352,8 +1352,10 @@ tty_keys_clipboard(struct tty *tty, const char *buf, size_t len, size_t *size)
end--; end--;
/* If we did not request this, ignore it. */ /* If we did not request this, ignore it. */
if (~tty->flags & TTY_OSC52QUERY) if (~tty->flags & TTY_OSC52QUERY) {
return (0); return options_get_number(global_options,
"forward-unrequested-escseq") ? (-1) : (0);
}
tty->flags &= ~TTY_OSC52QUERY; tty->flags &= ~TTY_OSC52QUERY;
evtimer_del(&tty->clipboard_timer); evtimer_del(&tty->clipboard_timer);