• R/O
  • SSH

vim: Commit

Mirror of the Vim source from https://github.com/vim/vim


Commit MetaInfo

Revisiónaa8fa32cdca3d9bdc698c892036489916d128253 (tree)
Tiempo2021-01-18 06:15:05
AutorBram Moolenaar <Bram@vim....>
CommiterBram Moolenaar

Log Message

patch 8.2.2374: accessing uninitialized memory in test_undo

Commit: https://github.com/vim/vim/commit/82aa6e09e02b138ab7ee6b79ecac487813f117e5
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jan 17 22:04:02 2021 +0100

patch 8.2.2374: accessing uninitialized memory in test_undo
Problem: Accessing uninitialized memory in test_undo.
Solution: Do not look in typebuf.tb_buf if it is empty. (Dominique Pellé,
closes #7697)

Cambiar Resumen

Diferencia incremental

diff -r d35c5eccbdad -r aa8fa32cdca3 src/edit.c
--- a/src/edit.c Sun Jan 17 22:00:04 2021 +0100
+++ b/src/edit.c Sun Jan 17 22:15:05 2021 +0100
@@ -1586,7 +1586,7 @@
15861586 // Recognize:
15871587 // form 0: {lead}{key};{modifier}u
15881588 // form 1: {lead}27;{modifier};{key}~
1589- if ((c == CSI || (c == ESC && *p == '[')) && typebuf.tb_len >= 4)
1589+ if (typebuf.tb_len >= 4 && (c == CSI || (c == ESC && *p == '[')))
15901590 {
15911591 idx = (*p == '[');
15921592 if (p[idx] == '2' && p[idx + 1] == '7' && p[idx + 2] == ';')
diff -r d35c5eccbdad -r aa8fa32cdca3 src/version.c
--- a/src/version.c Sun Jan 17 22:00:04 2021 +0100
+++ b/src/version.c Sun Jan 17 22:15:05 2021 +0100
@@ -751,6 +751,8 @@
751751 static int included_patches[] =
752752 { /* Add new patch number below this line */
753753 /**/
754+ 2374,
755+/**/
754756 2373,
755757 /**/
756758 2372,
Show on old repository browser