blob: aecab0b5679eed2adba398483f86c68da3c8ab6d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
From: Markus Koschany <apo@debian.org>
Date: Mon, 7 Nov 2022 00:03:56 +0100
Subject: CVE-2022-3099
Origin: https://github.com/vim/vim/commit/35d21c6830fc2d68aca838424a0e786821c5891c
---
src/ex_docmd.c | 2 +-
src/testdir/test_eval_stuff.vim | 14 ++++++++++++++
2 files changed, 15 insertions(+), 1 deletion(-)
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -1109,7 +1109,7 @@ do_cmdline(
/* Check for the next breakpoint at or after the ":while"
* or ":for". */
- if (breakpoint != NULL)
+ if (breakpoint != NULL && lines_ga.ga_len > current_line)
{
*breakpoint = dbg_find_breakpoint(
getline_equal(fgetline, cookie, getsourceline),
|