Fix the ordering of accumulated results.