summaryrefslogtreecommitdiff
path: root/src/ziplist.h
Commit message (Collapse)AuthorAgeFilesLines
* Add header guard for ziplist.hantirez2015-04-291-0/+5
| | | | As suggested in #2543.
* Add ziplistMerge()Matt Stancliff2015-01-021-0/+1
| | | | | | | | | | | | | | | This started out as #2158 by sunheehnus, but I kept rewriting it until I could understand things more easily and get a few more correctness guarantees out of the readability flow. The original commit created and returned a new ziplist with the contents of both input ziplists, but I prefer to grow one of the input ziplists and destroy the other one. So, instead of malloc+copy as in #2158, the merge now reallocs one of the existing ziplists and copies the other ziplist into the new space. Also added merge test cases to ziplistTest()
* Fix ziplistDeleteRange index parameterMatt Stancliff2014-12-231-1/+1
| | | | | It's valid to delete from negative offsets, so we *don't* want unsigned arguments here.
* Allow all code tests to run using Redis argsMatt Stancliff2014-12-231-0/+4
| | | | | | | | | | | | | | | | | | | | | Previously, many files had individual main() functions for testing, but each required being compiled with their own testing flags. That gets difficult when you have 8 different flags you need to set just to run all tests (plus, some test files required other files to be compiled aaginst them, and it seems some didn't build at all without including the rest of Redis). Now all individual test main() funcions are renamed to a test function for the file itself and one global REDIS_TEST define enables testing across the entire codebase. Tests can now be run with: - `./redis-server test <test>` e.g. ./redis-server test ziplist If REDIS_TEST is not defined, then no tests get included and no tests are included in the final redis-server binary.
* BSD license added to every C source and header file.antirez2012-11-081-0/+30
|
* Implements ziplistFindPieter Noordhuis2012-01-031-0/+1
| | | | | | To improve the performance of the ziplist implementation, some functions have been converted to macros to avoid unnecessary stack movement and duplicate variable assignments.
* encoded types API to get blob lengthantirez2011-02-281-1/+1
|
* redis.c split into many different C files.antirez2010-07-011-0/+15
networking related stuff moved into networking.c moved more code more work on layout of source code SDS instantaneuos memory saving. By Pieter and Salvatore at VMware ;) cleanly compiling again after the first split, now splitting it in more C files moving more things around... work in progress split replication code splitting more Sets split Hash split replication split even more splitting more splitting minor change