cat(1p): fixed write buffering

This commit is contained in:
2023-08-10 15:34:02 -06:00
parent b360b823ac
commit e530f10cd5

View File

@@ -107,7 +107,7 @@ int main(int argc, char *argv[]) {
}
}
fputs(buf, stdout);
fwrite(buf, 1, p, stdout);
fflush(stdout);
if (file != stdin) { fclose(file); }