Provide sort function for associative arrays.
The mu_assoc_sort_r call sorts the elements of mu_assoc_t for subsequent iterative access. Random access facilities remain undistrurbed. * include/mailutils/assoc.h (mu_assoc_comparator_t): New typedef. (mu_assoc_sort_r): New proto. * libmailutils/base/assoc.c (mu_assoc_sort_r): New function. * libmailutils/tests/mimehdr.c: Sort assoc elements prior to iteration.
Showing
4 changed files
with
143 additions
and
50 deletions
-
Please register or sign in to post a comment