fix the flush time out not reset bug.