Problem: Invalid memory access with bad 'statusline' value.
Solution: Avoid going over the NUL at the end.
#endif
if (vim_strchr(STL_ALL, *s) == NULL)
{
+ if (*s == NUL) // can happen with "%0"
+ break;
s++;
continue;
}
set splitbelow&
endfunc
+func Test_statusline_trailing_percent_zero()
+ " this was causing illegal memory access
+ set laststatus=2 stl=%!%0
+ call assert_fails('redraw', 'E15: Invalid expression: "%0"')
+ set laststatus& stl&
+endfunc
+
func Test_statusline_visual()
func CallWordcount()
call wordcount()
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1143,
/**/
1142,
/**/