Make output stream order according to the input order.