mirror of
https://github.com/tmux/tmux.git
synced 2025-01-12 03:08:46 +00:00
Merge branch 'obsd-master'
This commit is contained in:
commit
0c07b10b30
@ -1273,11 +1273,13 @@ window_copy_goto_line(struct window_pane *wp, const char *linestr)
|
||||
{
|
||||
struct window_copy_mode_data *data = wp->modedata;
|
||||
const char *errstr;
|
||||
u_int lineno;
|
||||
int lineno;
|
||||
|
||||
lineno = strtonum(linestr, 0, screen_hsize(data->backing), &errstr);
|
||||
lineno = strtonum(linestr, -1, INT_MAX, &errstr);
|
||||
if (errstr != NULL)
|
||||
return;
|
||||
if (lineno < 0 || (u_int)lineno > screen_hsize(data->backing))
|
||||
lineno = screen_hsize(data->backing);
|
||||
|
||||
data->oy = lineno;
|
||||
window_copy_update_selection(wp, 1);
|
||||
@ -2082,7 +2084,7 @@ window_copy_cursor_up(struct window_pane *wp, int scroll_only)
|
||||
}
|
||||
}
|
||||
|
||||
if (data->screen.sel != NULL || !data->rectflag) {
|
||||
if (data->screen.sel == NULL || !data->rectflag) {
|
||||
py = screen_hsize(data->backing) + data->cy - data->oy;
|
||||
px = window_copy_find_length(wp, py);
|
||||
if ((data->cx >= data->lastsx && data->cx != px) ||
|
||||
|
Loading…
Reference in New Issue
Block a user