diff --git a/src/console.c b/src/console.c index 432c1fc..d92a96e 100644 --- a/src/console.c +++ b/src/console.c @@ -17,6 +17,13 @@ #include +static void kernaux_console_printf_putc( + const char c, + void *const arg __attribute__((unused)) +) { + kernaux_console_putc(c); +} + void kernaux_console_putc(const char c __attribute__((unused))) { #ifdef ASM_I386 @@ -39,7 +46,7 @@ void kernaux_console_printf(const char *format, ...) { va_list va; va_start(va, format); - kernaux_vprintf(kernaux_console_putc, NULL, format, va); + kernaux_vprintf(kernaux_console_printf_putc, NULL, format, va); va_end(va); } #endif diff --git a/tests/test_printf.c b/tests/test_printf.c index 3996ce8..2ccc622 100644 --- a/tests/test_printf.c +++ b/tests/test_printf.c @@ -14,8 +14,10 @@ static char buffer[BUFFER_SIZE]; static size_t buffer_index; -static void test_putchar(const char chr) -{ +static void test_putchar( + const char chr, + void *const arg __attribute__((unused)) +) { if (buffer_index >= BUFFER_SIZE) { printf("Buffer overflow!\n"); abort();