From bbcc08a6b6188eb80bda12bbb1d2a8ad9d03d0a2 Mon Sep 17 00:00:00 2001 From: David Given Date: Mon, 28 Nov 2016 21:38:46 +0100 Subject: [PATCH] Fix putchar() return value. --- lang/b/lib/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lang/b/lib/main.c b/lang/b/lib/main.c index 1d18a800e..9b868bada 100644 --- a/lang/b/lib/main.c +++ b/lang/b/lib/main.c @@ -22,9 +22,10 @@ static intptr_t i_getchar(void) return fgetc(output_unit); } -static void i_putchar(intptr_t c) +static intptr_t i_putchar(intptr_t c) { fputc(c, output_unit); + return c; } uintptr_t b_char = (uintptr_t)i_char;