1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00

* stdlib/stdlib.h: Define __compar_d_fn_t. Declare qsort_r.

* include/stdlib.h: Add hidden_proto for qsort_t and adjust protoype
	for _quicksort.
	* stdlib/msort.c (qsort): Now a wrapper around qsort_r.
	(qsort_r): Renamed from qsort.  Take additional parameter and pass it
	on as third parameter to compare function and _quicksort.
	* stdlib/qsort.c (_quicksort): Take additional parameter and pass on
	to the compare function.
	* stdlib/Versions [libc] (GLIBC_2.8): Add qsort_r.
	* Versions.def: Add GLIBC_2.8 for libc.
This commit is contained in:
Ulrich Drepper
2007-11-13 17:21:43 +00:00
parent bd63f380d8
commit e458144c99
7 changed files with 57 additions and 21 deletions

View File

@ -32,6 +32,7 @@ libc_hidden_proto (abort)
libc_hidden_proto (getenv)
libc_hidden_proto (bsearch)
libc_hidden_proto (qsort)
libc_hidden_proto (qsort_r)
libc_hidden_proto (lrand48_r)
libc_hidden_proto (wctomb)
libc_hidden_proto (__secure_getenv)
@ -83,7 +84,7 @@ extern int __add_to_environ (const char *name, const char *value,
const char *combines, int replace);
extern void _quicksort (void *const pbase, size_t total_elems,
size_t size, __compar_fn_t cmp);
size_t size, __compar_d_fn_t cmp, void *arg);
extern int __on_exit (void (*__func) (int __status, void *__arg), void *__arg);