ovs-benchmark: improve 'rate' command piped output support.
authorAndy Zhou <azhou@nicira.com>
Mon, 29 Apr 2013 21:42:56 +0000 (14:42 -0700)
committerBen Pfaff <blp@nicira.com>
Thu, 2 May 2013 22:47:55 +0000 (15:47 -0700)
commitd5155945e03ffef6ff4de05d1ec5dfd0951e0860
tree31c113c0cb24ac837038b9c8b9cef99ac90fc1be
parent3cbb5dc7e89df2b40bb6f715873cf2b6b25a7054
ovs-benchmark: improve 'rate' command piped output support.

Add fflush() to the 'rate' command of 'ovs-benchmark'.  On a tty console
the output is line-buffered. However, piped output by default has a
deeper (usually 4KB) buffer, the output won't appear to the other end of
the pipe until this buffer is full.

This patch makes the piped output of the 'rate' command's consistent
with tty console output.

Signed-off-by: Andy Zhou <azhou@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
utilities/ovs-benchmark.c