Add fflush for manual stdio flushing.