physfs.c
branchstable-1.0
changeset 949 8badfbbb3b27
parent 900 c5172fa2c5e6
child 1288 2f4ad6a37f2e
equal deleted inserted replaced
940:a624957f6288 949:8badfbbb3b27
   212             while(cmpfn(a, --j, v) > 0) { /* do nothing */ }
   212             while(cmpfn(a, --j, v) > 0) { /* do nothing */ }
   213             if (j < i)
   213             if (j < i)
   214                 break;
   214                 break;
   215             swapfn(a, i, j);
   215             swapfn(a, i, j);
   216         } /* while */
   216         } /* while */
   217         swapfn(a, i, hi-1);
   217         if (i != (hi-1))
       
   218             swapfn(a, i, hi-1);
   218         __PHYSFS_quick_sort(a, lo, j, cmpfn, swapfn);
   219         __PHYSFS_quick_sort(a, lo, j, cmpfn, swapfn);
   219         __PHYSFS_quick_sort(a, i+1, hi, cmpfn, swapfn);
   220         __PHYSFS_quick_sort(a, i+1, hi, cmpfn, swapfn);
   220     } /* else */
   221     } /* else */
   221 } /* __PHYSFS_quick_sort */
   222 } /* __PHYSFS_quick_sort */
   222 
   223