fix buffering with flushes - lchat - A line oriented chat front end for ii. | |
git clone git://git.suckless.org/lchat | |
Log | |
Files | |
Refs | |
README | |
--- | |
commit 0f9c10417a8ab19e6658aece630df0816efa05ba | |
parent 95228a60c30fb237075d22213c2cb241af259c1f | |
Author: Jan Klemkow <[email protected]> | |
Date: Mon, 28 Nov 2016 22:10:21 +0100 | |
fix buffering with flushes | |
Diffstat: | |
M filter/indent.c | 2 ++ | |
1 file changed, 2 insertions(+), 0 deletions(-) | |
--- | |
diff --git a/filter/indent.c b/filter/indent.c | |
@@ -18,6 +18,7 @@ main(int argc, char *argv[]) | |
if (next == NULL || next[0] == '-') { | |
fputs(buf, stdout); | |
+ fflush(stdout); | |
continue; | |
} | |
@@ -43,6 +44,7 @@ main(int argc, char *argv[]) | |
fputc(' ', stdout); | |
fputs(word, stdout); | |
+ fflush(stdout); | |
} | |
} | |