diff options
author | antirez <antirez@gmail.com> | 2009-05-19 17:34:30 +0200 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2009-05-19 17:34:30 +0200 |
commit | 75fd597daf80800feb18eab312c5f99e4c22e567 (patch) | |
tree | 565bae8e0b9c13e3bb883449a2ae3b8050915ac3 /pqsort.h | |
parent | f4f56e1dfba6c8b9b0654f332420fc2e4933fda3 (diff) | |
download | redis-75fd597daf80800feb18eab312c5f99e4c22e567.tar.gz |
psort.c/h added. This is a partial qsort implementation that Redis will use when SORT+LIMIT is requested
Diffstat (limited to 'pqsort.h')
-rw-r--r-- | pqsort.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/pqsort.h b/pqsort.h new file mode 100644 index 000000000..10b81147a --- /dev/null +++ b/pqsort.h @@ -0,0 +1,15 @@ +/* The following is the NetBSD libc qsort implementation modified in order to + * support partial sorting of ranges for Redis. + * + * Copyright(C) 2009 Salvatore Sanfilippo. All rights reserved. + * + * See the pqsort.c file for the original copyright notice. */ + +#ifndef __PQSORT_H +#define __PQSORT_H + +void +pqsort(void *a, size_t n, size_t es, + int (*cmp) __P((const void *, const void *)), size_t lrange, size_t rrange) + +#endif |