mirror of
https://github.com/neovim/neovim.git
synced 2026-08-28 10:01:49 +00:00
vim-patch:8.2.0063: wrong size argument to vim_snprintf()
Problem: Wrong size argument to vim_snprintf(). (Dominique Pelle)
Solution: Reduce the size by the length. (related to vim/vim#5410)
08b28b7ad5
This commit is contained in:
@@ -5654,7 +5654,8 @@ void cursor_pos_info(dict_T *dict)
|
||||
|
||||
bom_count = bomb_size();
|
||||
if (dict == NULL && bom_count > 0) {
|
||||
vim_snprintf((char *)IObuff + STRLEN(IObuff), IOSIZE - STRLEN(IObuff),
|
||||
const size_t len = STRLEN(IObuff);
|
||||
vim_snprintf((char *)IObuff + len, IOSIZE - len,
|
||||
_("(+%" PRId64 " for BOM)"), (int64_t)bom_count);
|
||||
}
|
||||
if (dict == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user