fputc() fixes

This commit is contained in:
Max Wash
2020-08-07 20:30:56 +01:00
parent 37b28d5789
commit eaa968b98e
2 changed files with 6 additions and 6 deletions

View File

@@ -10,5 +10,10 @@ int fputs(const char *str, FILE *fp)
} }
} }
__fio_write(fp, "\n", 1);
if (__fio_error(fp)) {
return EOF;
}
return 0; return 0;
} }

View File

@@ -2,10 +2,5 @@
int puts(const char *str) int puts(const char *str)
{ {
int ret = fputs(str, stdout); return fputs(str, stdout);
if (ret < 0) {
return ret;
}
return fputc('\n', stdout);
} }