summaryrefslogtreecommitdiff
path: root/m4/stdlib_h.m4
Commit message (Expand)AuthorAgeFilesLines
* Vector-sorting fixes....It's not safe to call qsort or qsort_r, since they have undefined behavior if the user-specified predicate is not a total order. Also, watch out for garbage-collection while sorting vectors. * admin/merge-gnulib (GNULIB_MODULES): Add vla. * configure.ac (qsort_r): Remove, as we no longer use qsort-like functions. * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate. * lib/vla.h, m4/vararrays.m4: New files, copied from gnulib. * lib/stdlib.in.h, m4/stdlib_h.m4: Sync from gnulib, incorporating: 2014-08-29 qsort_r: new module, for GNU-style qsort_r The previous two files' changes are boilerplate generated by admin/merge-gnulib, and should not affect Emacs. * src/fns.c: Include <vla.h>. (sort_vector_predicate) [!HAVE_QSORT_R]: Remove. (sort_vector_compare): Remove, replacing with .... (inorder, merge_vectors, sort_vector_inplace, sort_vector_copy): ... these new functions. (sort_vector): Rewrite to use the new functions. GCPRO locals, since the predicate can invoke the GC. Since it's in-place return void; caller changed. (merge): Use 'inorder', for clarity. Fixes: debbugs:18361 Paul Eggert2014-08-301-0/+2
* Update copyright year to 2014 by running admin/update-copyright.Paul Eggert2014-01-011-1/+1
* Merge from gnulib.Paul Eggert2013-02-081-2/+4
* Update copyright notices for 2013.Paul Eggert2013-01-011-1/+1
* Merge from gnulib.Paul Eggert2012-10-041-0/+1
* Merge from gnulib....Fixes: debbugs:11527 Paul Eggert2012-05-261-6/+15
* Regenerate.Paul Eggert2011-02-241-1/+5
* Import getloadavg module from gnulib.Paul Eggert2011-02-151-0/+101