mirror of
https://github.com/neovim/neovim.git
synced 2025-09-27 05:28:33 +00:00
Remove sizeof(int) < 4 related code
This commit is contained in:

committed by
Thiago de Arruda

parent
0072ba9361
commit
b10341ce5b
@@ -3351,14 +3351,10 @@ int vim_vsnprintf(char *str, size_t str_m, char *fmt, va_list ap, typval_T *tvs)
|
||||
else {
|
||||
/* Don't put the #if inside memchr(), it can be a
|
||||
* macro. */
|
||||
#if SIZEOF_INT <= 2
|
||||
char *q = memchr(str_arg, '\0', precision);
|
||||
#else
|
||||
/* memchr on HP does not like n > 2^31 !!! */
|
||||
char *q = memchr(str_arg, '\0',
|
||||
precision <= (size_t)0x7fffffffL ? precision
|
||||
: (size_t)0x7fffffffL);
|
||||
#endif
|
||||
str_arg_l = (q == NULL) ? precision
|
||||
: (size_t)(q - str_arg);
|
||||
}
|
||||
|
Reference in New Issue
Block a user