diff options
-rw-r--r-- | lib/lib.c | 2 | ||||
-rw-r--r-- | main.c | 4 |
2 files changed, 3 insertions, 3 deletions
@@ -160,7 +160,7 @@ void xputs(char *s) void xputc(char c) { - if (EOF == fputc(c, stdout)) perror_exit("write"); + if (EOF == fputc(c, stdout) || fflush(stdout)) perror_exit("write"); } void xflush(void) @@ -133,12 +133,12 @@ void toybox_main(void) } len += printf("%s ",toy_list[i].name); if (len>65) { - putchar('\n'); + xputc('\n'); len=0; } } } - putchar('\n'); + xputc('\n'); } int main(int argc, char *argv[]) |