lnstat : force a flush before sleep

Hi Stephen

This small patch allows to use lnstat/rtstat with a pipe output, without a full bufferisation.

Thank you
Eric

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
This commit is contained in:
Eric Dumazet 2007-09-27 14:26:09 +02:00 committed by Stephen Hemminger
parent 13010712c5
commit f50332c57a
1 changed files with 1 additions and 0 deletions

View File

@ -328,6 +328,7 @@ int main(int argc, char **argv)
print_hdr(stdout, header);
lnstat_update(lnstat_files);
print_line(stdout, lnstat_files, &fp);
fflush(stdout);
sleep(interval);
}
}