11 Commits

Author SHA1 Message Date
Matt Stancliff
c82e0b701f Fix intset midpoint selection
The classic (min+max)/2 is provably unsafe.  Fixed
as recommended in research:
http://googleresearch.blogspot.com/2006/06/extra-extra-read-all-about-it-nearly.html

Fix inspired by @wjin, but I used a different approach.
(later, I found @kuebler fixed the same issue too).

Fixes #1741, #1602
2014-08-07 16:17:37 +02:00
antirez
4365e5b2d3 BSD license added to every C source and header file. 2012-11-08 18:31:32 +01:00
antirez
7a3e372025 endian.c/h -> endianconv.c/h to avoid issues with broken libraries search paths. 2012-02-14 16:11:46 +01:00
antirez
6136a16bd1 intset.c endianess fixes. 2012-02-14 15:35:50 +01:00
antirez
dc75b1edfb encoding agnostic intsets 2011-03-09 19:14:04 +01:00
antirez
d4fb9f4144 encoded types API to get blob length 2011-02-28 14:48:49 +01:00
antirez
a5be65f71c COW friendly versions of SPOP and SRANDMEMBER commands, with some change to the set encoding-agnostic API. 2010-12-09 10:21:02 +01:00
Pieter Noordhuis
740eee1cc6 Fix type that was not renamed and compiler warning 2010-08-26 12:13:51 +02:00
Pieter Noordhuis
f9d5c4e33c Make the function intsetUpgrade self-contained 2010-08-26 11:22:58 +02:00
Pieter Noordhuis
76864d5626 Expand macro's to functions for readability 2010-08-26 11:06:30 +02:00
Pieter Noordhuis
96ffb2fe97 merged intset code into the split files 2010-07-02 19:57:12 +02:00