1
0
forked from aniani/vim

patch 7.4.2067

Problem:    Compiler warning for char/char_u conversion. (Tony Mechelynck)
            Inefficient code.
Solution:   Use more lines to fill with spaces. (Nikolai Pavlov) Add type cast.
This commit is contained in:
Bram Moolenaar
2016-07-18 22:22:39 +02:00
parent c1fb763184
commit 16ec3c9be3
2 changed files with 10 additions and 3 deletions

View File

@@ -2593,9 +2593,14 @@ qf_msg(qf_info_T *qi, int which, char *lead)
if (title != NULL)
{
while (STRLEN(buf) < 34)
STRCAT(buf, " ");
vim_strcat(buf, title, IOSIZE);
size_t len = STRLEN(buf);
if (len < 34)
{
vim_memset(buf + len, ' ', 34 - len);
buf[34] = NUL;
}
vim_strcat(buf, (char_u *)title, IOSIZE);
}
trunc_string(buf, buf, Columns - 1, IOSIZE);
msg(buf);