diff options
Diffstat (limited to 'debian/patches/CVE-2022-0213.patch')
-rw-r--r-- | debian/patches/CVE-2022-0213.patch | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/debian/patches/CVE-2022-0213.patch b/debian/patches/CVE-2022-0213.patch new file mode 100644 index 0000000..bb1c91b --- /dev/null +++ b/debian/patches/CVE-2022-0213.patch @@ -0,0 +1,48 @@ +From: Markus Koschany <apo@debian.org> +Date: Sun, 23 Oct 2022 16:01:20 +0200 +Subject: CVE-2022-0213 + +Origin: https://github.com/vim/vim/commit/de05bb25733c3319e18dca44e9b59c6ee389eb26 +--- + src/screen.c | 3 ++- + src/testdir/test_edit.vim | 14 ++++++++++++++ + 2 files changed, 16 insertions(+), 1 deletion(-) + +--- a/src/screen.c ++++ b/src/screen.c +@@ -6878,12 +6878,13 @@ win_redr_status(win_T *wp, int ignore_pu + p = NameBuff; + len = (int)STRLEN(p); + +- if (bt_help(wp->w_buffer) ++ if ((bt_help(wp->w_buffer) + #ifdef FEAT_QUICKFIX + || wp->w_p_pvw + #endif + || bufIsChanged(wp->w_buffer) + || wp->w_buffer->b_p_ro) ++ && len < MAXPATHL - 1) + *(p + len++) = ' '; + if (bt_help(wp->w_buffer)) + { +--- a/src/testdir/test_edit.vim ++++ b/src/testdir/test_edit.vim +@@ -1449,4 +1449,18 @@ func Test_edit_put_CTRL_E() + set encoding=utf-8 + endfunc + ++" CVE-2022-0213 ++func Test_edit_overlong_file_name() ++ ++ file 0000000000000000000000000000 ++ file %%%%%%%%%%%%%%%%%%%%%%%%%% ++ file %%%%%% ++ set readonly ++ set ls=2 ++ ++ redraw! ++ set noreadonly ls& ++ bwipe! ++endfunc ++ + " vim: shiftwidth=2 sts=2 expandtab |