mirror of
https://github.com/neovim/neovim.git
synced 2026-05-01 11:34:56 +00:00
coverity/155511: Pass correct length argument to strncat()
This commit is contained in:
@@ -1408,8 +1408,8 @@ char_u *make_filter_cmd(char_u *cmd, char_u *itmp, char_u *otmp)
|
||||
}
|
||||
|
||||
if (itmp != NULL) {
|
||||
strncat(buf, " < ", len);
|
||||
strncat(buf, (char *) itmp, len);
|
||||
strncat(buf, " < ", len - 1);
|
||||
strncat(buf, (const char *)itmp, len - 1);
|
||||
}
|
||||
#else
|
||||
// For shells that don't understand braces around commands, at least allow
|
||||
|
||||
Reference in New Issue
Block a user