C: General Insertion Sort