1
0
mirror of https://github.com/tmux/tmux.git synced 2025-04-16 16:38:49 +00:00

Merge branch 'obsd-master'

This commit is contained in:
Thomas Adam 2018-04-23 17:02:32 +01:00
commit d24bd7394d
4 changed files with 15 additions and 14 deletions

View File

@ -89,10 +89,8 @@ cmd_display_message_exec(struct cmd *self, struct cmdq_item *item)
msg = format_expand_time(ft, template, time(NULL)); msg = format_expand_time(ft, template, time(NULL));
if (args_has(self->args, 'p')) if (args_has(self->args, 'p'))
cmdq_print(item, "%s", msg); cmdq_print(item, "%s", msg);
else { else if (c != NULL)
if (c != NULL)
status_message_set(c, "%s", msg); status_message_set(c, "%s", msg);
}
free(msg); free(msg);
format_free(ft); format_free(ft);

View File

@ -513,8 +513,8 @@ const struct options_table_entry options_table[] = {
{ .name = "update-environment", { .name = "update-environment",
.type = OPTIONS_TABLE_ARRAY, .type = OPTIONS_TABLE_ARRAY,
.scope = OPTIONS_TABLE_SESSION, .scope = OPTIONS_TABLE_SESSION,
.default_str = "DISPLAY SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID " .default_str = "DISPLAY KRB5CCNAME SSH_ASKPASS SSH_AUTH_SOCK "
"SSH_CONNECTION WINDOWID XAUTHORITY" "SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY"
}, },
{ .name = "visual-activity", { .name = "visual-activity",

3
tmux.1
View File

@ -2755,8 +2755,7 @@ to
from the 256-colour set, from the 256-colour set,
.Ic default , .Ic default ,
or a hexadecimal RGB string such as or a hexadecimal RGB string such as
.Ql #ffffff , .Ql #ffffff .
which chooses the closest match from the default 256-colour set.
.Pp .Pp
The attributes is either The attributes is either
.Ic none .Ic none

View File

@ -1548,7 +1548,7 @@ window_copy_get_selection(struct window_pane *wp, size_t *len)
char *buf; char *buf;
size_t off; size_t off;
u_int i, xx, yy, sx, sy, ex, ey, ey_last; u_int i, xx, yy, sx, sy, ex, ey, ey_last;
u_int firstsx, lastex, restex, restsx; u_int firstsx, lastex, restex, restsx, selx;
int keys; int keys;
if (!s->sel.flag && s->sel.lineflag == LINE_SEL_NONE) if (!s->sel.flag && s->sel.lineflag == LINE_SEL_NONE)
@ -1599,7 +1599,11 @@ window_copy_get_selection(struct window_pane *wp, size_t *len)
* Need to ignore the column with the cursor in it, which for * Need to ignore the column with the cursor in it, which for
* rectangular copy means knowing which side the cursor is on. * rectangular copy means knowing which side the cursor is on.
*/ */
if (data->selx < data->cx) { if (data->cursordrag == CURSORDRAG_ENDSEL)
selx = data->selx;
else
selx = data->endselx;
if (selx < data->cx) {
/* Selection start is on the left. */ /* Selection start is on the left. */
if (keys == MODEKEY_EMACS) { if (keys == MODEKEY_EMACS) {
lastex = data->cx; lastex = data->cx;
@ -1609,12 +1613,12 @@ window_copy_get_selection(struct window_pane *wp, size_t *len)
lastex = data->cx + 1; lastex = data->cx + 1;
restex = data->cx + 1; restex = data->cx + 1;
} }
firstsx = data->selx; firstsx = selx;
restsx = data->selx; restsx = selx;
} else { } else {
/* Cursor is on the left. */ /* Cursor is on the left. */
lastex = data->selx + 1; lastex = selx + 1;
restex = data->selx + 1; restex = selx + 1;
firstsx = data->cx; firstsx = data->cx;
restsx = data->cx; restsx = data->cx;
} }