libxo needs to allow for explicit flushing of output streams when doing
time series output. example: 'netstat --libxo json 1'
Without the flush, then the output is buffered until the stdio buffer
fills.
This patch adds a non-standard (but yet standard in glibc and
solaris) function to peek into stdio buffers to determine if they are
line buffered so that libxo can properly buffer based on lines.