Ensure data is flushed.