mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
Fix warnings: edit.c: mb_replace_pop_ins(): Unitilialized arg: FP.
Problem : Uninitialized argument value @ 6296. Diagnostic : False positive. Rationale : Error occurs if n <= 1. That's not possible because n >= 1 due to `MB_BYTE2LEN` postcondition and n != 1 because we are in the else branch. Resolution : Assert n > 1.
This commit is contained in:
parent
da4c9447a4
commit
cefc26ab63
@ -6290,6 +6290,7 @@ static void mb_replace_pop_ins(int cc)
|
||||
break;
|
||||
} else {
|
||||
buf[0] = c;
|
||||
assert(n > 1);
|
||||
for (i = 1; i < n; ++i)
|
||||
buf[i] = replace_pop();
|
||||
if (utf_iscomposing(utf_ptr2char(buf)))
|
||||
|
Loading…
Reference in New Issue
Block a user