mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 9.1.1072: 'diffopt' "linematch" cannot be used with {n} less than 10
Problem: 'diffopt' "linematch" cannot be used with {n} less than 10 digits (after v9.1.1022) Solution: Fix off-by-one error when checking for digit (zeertzjq) closes: #16577 Signed-off-by: zeertzjq <zeertzjq@outlook.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
04d2a3fdc0
commit
ccd7f454fc
@@ -2795,7 +2795,7 @@ diffopt_changed(void)
|
|||||||
else
|
else
|
||||||
return FAIL;
|
return FAIL;
|
||||||
}
|
}
|
||||||
else if (STRNCMP(p, "linematch:", 10) == 0 && VIM_ISDIGIT(p[11]))
|
else if (STRNCMP(p, "linematch:", 10) == 0 && VIM_ISDIGIT(p[10]))
|
||||||
{
|
{
|
||||||
p += 10;
|
p += 10;
|
||||||
linematch_lines_new = getdigits(&p);
|
linematch_lines_new = getdigits(&p);
|
||||||
|
@@ -178,9 +178,11 @@ let test_values = {
|
|||||||
\ 'icase', 'iwhite', 'iwhiteall', 'horizontal', 'vertical',
|
\ 'icase', 'iwhite', 'iwhiteall', 'horizontal', 'vertical',
|
||||||
\ 'closeoff', 'hiddenoff', 'foldcolumn:0', 'foldcolumn:12',
|
\ 'closeoff', 'hiddenoff', 'foldcolumn:0', 'foldcolumn:12',
|
||||||
\ 'followwrap', 'internal', 'indent-heuristic', 'algorithm:myers',
|
\ 'followwrap', 'internal', 'indent-heuristic', 'algorithm:myers',
|
||||||
\ 'algorithm:minimal', 'algorithm:patience',
|
\ 'icase,iwhite', 'algorithm:minimal', 'algorithm:patience',
|
||||||
\ 'algorithm:histogram', 'icase,iwhite'],
|
\ 'algorithm:histogram', 'linematch:5'],
|
||||||
\ ['xxx', 'foldcolumn:xxx', 'algorithm:xxx', 'algorithm:']],
|
\ ['xxx', 'foldcolumn:', 'foldcolumn:x', 'foldcolumn:xxx',
|
||||||
|
\ 'linematch:', 'linematch:x', 'linematch:xxx', 'algorithm:',
|
||||||
|
\ 'algorithm:xxx', 'context:', 'context:x', 'context:xxx']],
|
||||||
\ 'display': [['', 'lastline', 'truncate', 'uhex', 'lastline,uhex'],
|
\ 'display': [['', 'lastline', 'truncate', 'uhex', 'lastline,uhex'],
|
||||||
\ ['xxx']],
|
\ ['xxx']],
|
||||||
\ 'eadirection': [['', 'both', 'ver', 'hor'], ['xxx', 'ver,hor']],
|
\ 'eadirection': [['', 'both', 'ver', 'hor'], ['xxx', 'ver,hor']],
|
||||||
|
@@ -704,6 +704,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1072,
|
||||||
/**/
|
/**/
|
||||||
1071,
|
1071,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user