mirror of
https://github.com/neovim/neovim.git
synced 2024-12-20 19:25:11 -07:00
Use portable format specifiers: Case %l[uoxX] - plain - sprintf.
Fix uses of plain "%lu", "%lo", "%lx" and "%lX" within sprintf(): - Replace "%l<whatever>" with "%" PRI<whatever>64. - Cast corresponding argument to (uint64_t).
This commit is contained in:
parent
b9c550ebd5
commit
357f54f331
@ -4451,13 +4451,13 @@ int do_addsub(int command, linenr_T Prenum1)
|
||||
* Put the number characters in buf2[].
|
||||
*/
|
||||
if (hex == 0)
|
||||
sprintf((char *)buf2, "%lu", n);
|
||||
sprintf((char *)buf2, "%" PRIu64, (uint64_t)n);
|
||||
else if (hex == '0')
|
||||
sprintf((char *)buf2, "%lo", n);
|
||||
sprintf((char *)buf2, "%" PRIo64, (uint64_t)n);
|
||||
else if (hex && hexupper)
|
||||
sprintf((char *)buf2, "%lX", n);
|
||||
sprintf((char *)buf2, "%" PRIX64, (uint64_t)n);
|
||||
else
|
||||
sprintf((char *)buf2, "%lx", n);
|
||||
sprintf((char *)buf2, "%" PRIx64, (uint64_t)n);
|
||||
length -= (int)STRLEN(buf2);
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user