ucx/dlist.c

changeset 36
a9d656e4f7ce
parent 35
fdabd1240b69
child 37
ec296899d12f
equal deleted inserted replaced
35:fdabd1240b69 36:a9d656e4f7ce
143 ucx_dlist_qsort_sort(list, l, m-1, f, d); 143 ucx_dlist_qsort_sort(list, l, m-1, f, d);
144 ucx_dlist_qsort_sort(list, m+1, r, f, d); 144 ucx_dlist_qsort_sort(list, m+1, r, f, d);
145 } 145 }
146 } 146 }
147 147
148 UcxDlist *ucx_dlist_qsort(UcxDlist *l, cmp_func fnc, void *data) { 148 UcxDlist *ucx_dlist_sort(UcxDlist *l, cmp_func fnc, void *data) {
149 if (l == NULL) { 149 if (l == NULL) {
150 return NULL; 150 return NULL;
151 } 151 }
152 size_t n = ucx_dlist_size(l); 152 size_t n = ucx_dlist_size(l);
153 if (n == 1) { 153 if (n == 1) {

mercurial