mirror of
https://github.com/vim/vim.git
synced 2025-10-06 05:44:14 -04:00
patch 8.2.3855: illegal memory access when displaying a blob
Problem: Illegal memory access when displaying a blob. Solution: Append a NUL at the end. (Yegappan Lakshmanan, closes #9372)
This commit is contained in:
committed by
Bram Moolenaar
parent
86b3ab4fa0
commit
bc404bfb32
@@ -2917,20 +2917,20 @@ nfa_print_state2(FILE *debugf, nfa_state_T *state, garray_T *indent)
|
||||
ga_concat(indent, (char_u *)"| ");
|
||||
else
|
||||
ga_concat(indent, (char_u *)" ");
|
||||
ga_append(indent, '\0');
|
||||
ga_append(indent, NUL);
|
||||
|
||||
nfa_print_state2(debugf, state->out, indent);
|
||||
|
||||
// replace last part of indent for state->out1
|
||||
indent->ga_len -= 3;
|
||||
ga_concat(indent, (char_u *)" ");
|
||||
ga_append(indent, '\0');
|
||||
ga_append(indent, NUL);
|
||||
|
||||
nfa_print_state2(debugf, state->out1, indent);
|
||||
|
||||
// shrink indent
|
||||
indent->ga_len -= 3;
|
||||
ga_append(indent, '\0');
|
||||
ga_append(indent, NUL);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user