From eb84566d236df6b0dd4f5ce8fc47d66e55e33654 Mon Sep 17 00:00:00 2001 From: aqua Date: Thu, 29 Jun 2023 21:45:11 +0300 Subject: Fix compiler warnings --- lib/libk/string/itoa.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/libk/string') diff --git a/lib/libk/string/itoa.c b/lib/libk/string/itoa.c index 2db9768..0997345 100644 --- a/lib/libk/string/itoa.c +++ b/lib/libk/string/itoa.c @@ -4,7 +4,7 @@ static const char *numbers = "0123456789abcdef"; char * -utoa(char *p, unsigned x, int base) +utoa(char *p, unsigned x, unsigned base) { p += 3 * sizeof(unsigned); *--p = '\0'; @@ -18,12 +18,12 @@ utoa(char *p, unsigned x, int base) } char * -itoa(char *p, int x, int base) +itoa(char *p, int x, unsigned base) { const bool is_negative = (x < 0); if (is_negative) x = -x; - p = utoa(p, x, base); + p = utoa(p, (unsigned)x, base); if (is_negative) *--p = '-'; return p; -- cgit v1.2.1