Mercurial > vim
comparison src/move.c @ 26061:787c8061c747 v8.2.3564
patch 8.2.3564: invalid memory access when scrolling without valid screen
Commit: https://github.com/vim/vim/commit/777e7c21b7627be80961848ac560cb0a9978ff43
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Oct 25 17:07:04 2021 +0100
patch 8.2.3564: invalid memory access when scrolling without valid screen
Problem: Invalid memory access when scrolling without a valid screen.
Solution: Do not set VALID_BOTLINE in w_valid.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 25 Oct 2021 18:15:03 +0200 |
parents | a63676a1da2b |
children | fc859aea8cec |
comparison
equal
deleted
inserted
replaced
26060:b392baba0478 | 26061:787c8061c747 |
---|---|
197 if (!screen_valid(TRUE) || curwin->w_height == 0) | 197 if (!screen_valid(TRUE) || curwin->w_height == 0) |
198 { | 198 { |
199 check_cursor_lnum(); | 199 check_cursor_lnum(); |
200 curwin->w_topline = curwin->w_cursor.lnum; | 200 curwin->w_topline = curwin->w_cursor.lnum; |
201 curwin->w_botline = curwin->w_topline; | 201 curwin->w_botline = curwin->w_topline; |
202 curwin->w_valid |= VALID_BOTLINE|VALID_BOTLINE_AP; | |
203 curwin->w_scbind_pos = 1; | 202 curwin->w_scbind_pos = 1; |
204 return; | 203 return; |
205 } | 204 } |
206 | 205 |
207 check_cursor_moved(curwin); | 206 check_cursor_moved(curwin); |