To: vim_dev@googlegroups.com Subject: Patch 8.1.1664 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.1.1664 Problem: GUI resize may cause changing Rows at a bad time. (Dominique Pelle) Solution: Postpone resizing while updating the screen. Files: src/term.c *** ../vim-8.1.1663/src/term.c 2019-06-06 15:19:28.247404537 +0200 --- src/term.c 2019-07-12 15:31:59.684131412 +0200 *************** *** 3425,3435 **** if (State == HITRETURN || State == SETWSIZE) { ! /* postpone the resizing */ State = SETWSIZE; return; } /* curwin->w_buffer can be NULL when we are closing a window and the * buffer has already been closed and removing a scrollbar causes a resize * event. Don't resize then, it will happen after entering another buffer. --- 3425,3439 ---- if (State == HITRETURN || State == SETWSIZE) { ! // postpone the resizing State = SETWSIZE; return; } + if (updating_screen) + // resizing while in update_screen() may cause a crash + return; + /* curwin->w_buffer can be NULL when we are closing a window and the * buffer has already been closed and removing a scrollbar causes a resize * event. Don't resize then, it will happen after entering another buffer. *** ../vim-8.1.1663/src/version.c 2019-07-12 13:59:16.771261635 +0200 --- src/version.c 2019-07-12 15:36:54.586862235 +0200 *************** *** 779,780 **** --- 779,782 ---- { /* Add new patch number below this line */ + /**/ + 1664, /**/ -- FATHER: We are here today to witness the union of two young people in the joyful bond of the holy wedlock. Unfortunately, one of them, my son Herbert, has just fallen to his death. [Murmurs from CROWD; the BRIDE smiles with relief, coughs.] "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///