Flush stdout to avoid getting buffered results.