diff options
| author | Thomas Ulmer <thomasmulmer02@gmail.com> | 2026-06-23 21:34:41 -0700 |
|---|---|---|
| committer | Thomas Ulmer <thomasmulmer02@gmail.com> | 2026-06-23 21:34:41 -0700 |
| commit | 874d317334fae1ddce316f9b6f4d0ce4e434bf52 (patch) | |
| tree | 929f924d3c3696d3aa9917aca0e7048bbe3e93e8 /printf.c | |
| parent | 15bd7946cc838a3151c357e4b0bc1ab85eecda62 (diff) | |
heirloom vi fixes from arch AUR
Diffstat (limited to 'printf.c')
| -rw-r--r-- | printf.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -99,7 +99,7 @@ char *p_dconv(long, char *); static int p_emit(char *, char *); int -printf(const char *fmt, ...) +ex_printf(char *fmt, ...) { va_list ap; int ret; @@ -252,7 +252,7 @@ vprintf(const char *fmt, va_list ap) *--bptr = ((int) num & mask1) + 060; else *--bptr = ((int) num & mask1) + 0127; - while (num = (num >> nbits) & mask2); + while ((num = (num >> nbits) & mask2)); if (fcode=='o') { if (n) @@ -288,7 +288,7 @@ vprintf(const char *fmt, va_list ap) else num = (long) n; } - if (n = (fcode != 'u' && num < 0)) + if ((n = (fcode != 'u' && num < 0))) num = -num; /* now convert to digits */ bptr = p_dconv(num, buf); @@ -359,7 +359,7 @@ p_dconv(long value, char *buffer) */ bp += MAXDIGS + 1; while (value > LRGINT) { - *--bp = (int)(value % 10) + '0'; + *--bp = (value % 10) + '0'; value /= 10; } |
