kernel/range.c: fix clean_sort_range() for the case of full array