mirror of
https://github.com/fluencelabs/redis
synced 2025-04-01 15:21:03 +00:00
version incremented to 1.050 to distinguish from 1.001 stable and next stable versions with minor fixes
This commit is contained in:
parent
2c65cbc9e3
commit
1812e0246c
12
Changelog
12
Changelog
@ -1,3 +1,15 @@
|
|||||||
|
2009-10-21 TODO updated
|
||||||
|
2009-10-21 SRANDMEMBER added
|
||||||
|
2009-10-20 Imporant bug leading to data corruption fixed (NOT affecting stable distribution), Tcl client lib MSET/MSETNX implementation fixed, Added new tests for MSET and MSETNX in test-redis.tcl
|
||||||
|
2009-10-17 added multi-bulk protocol support to redis-cli and support for MSET and MSETNX
|
||||||
|
2009-10-17 MSET fixed, was not able to replace keys already set for a stupid bug
|
||||||
|
2009-10-16 some dead code removed
|
||||||
|
2009-10-16 multi bulk input protocol fixed
|
||||||
|
2009-10-16 MSET and MSETNX commands implemented
|
||||||
|
2009-10-07 undoed all the sds hacking that lead just to random bugs and no memory saving ;)
|
||||||
|
2009-10-07 initial multi-bulk query protocol, this will allow MSET and other interesting features.
|
||||||
|
2009-10-03 benchmark now outputs the right command line to shorten the TIME_WAIT interval on Mac OS X when keep alive is set
|
||||||
|
2009-10-02 Issue 69 fixed. Object integer encoding now works with replication and MONITORing again.
|
||||||
2009-09-18 LREM fixed, used to crash since the new object integer encoding is on the stage
|
2009-09-18 LREM fixed, used to crash since the new object integer encoding is on the stage
|
||||||
2009-09-17 maxmemory didn't worked in 64 systems for values > 4GB since it used to be an unsigned int. Fixed
|
2009-09-17 maxmemory didn't worked in 64 systems for values > 4GB since it used to be an unsigned int. Fixed
|
||||||
2009-09-10 incremented version number to 1.001, AKA Redis edge is no longer stable...
|
2009-09-10 incremented version number to 1.001, AKA Redis edge is no longer stable...
|
||||||
|
31
redis.c
31
redis.c
@ -27,7 +27,7 @@
|
|||||||
* POSSIBILITY OF SUCH DAMAGE.
|
* POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define REDIS_VERSION "1.001"
|
#define REDIS_VERSION "1.050"
|
||||||
|
|
||||||
#include "fmacros.h"
|
#include "fmacros.h"
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
@ -102,7 +102,8 @@
|
|||||||
#define REDIS_STRING 0
|
#define REDIS_STRING 0
|
||||||
#define REDIS_LIST 1
|
#define REDIS_LIST 1
|
||||||
#define REDIS_SET 2
|
#define REDIS_SET 2
|
||||||
#define REDIS_HASH 3
|
#define REDIS_ZSET 3
|
||||||
|
#define REDIS_HASH 4
|
||||||
|
|
||||||
/* Objects encoding */
|
/* Objects encoding */
|
||||||
#define REDIS_ENCODING_RAW 0 /* Raw representation */
|
#define REDIS_ENCODING_RAW 0 /* Raw representation */
|
||||||
@ -304,6 +305,11 @@ typedef struct _redisSortOperation {
|
|||||||
robj *pattern;
|
robj *pattern;
|
||||||
} redisSortOperation;
|
} redisSortOperation;
|
||||||
|
|
||||||
|
typedef struct zset {
|
||||||
|
dict *dict;
|
||||||
|
tree *tree;
|
||||||
|
} zset;
|
||||||
|
|
||||||
struct sharedObjectsStruct {
|
struct sharedObjectsStruct {
|
||||||
robj *crlf, *ok, *err, *emptybulk, *czero, *cone, *pong, *space,
|
robj *crlf, *ok, *err, *emptybulk, *czero, *cone, *pong, *space,
|
||||||
*colon, *nullbulk, *nullmultibulk,
|
*colon, *nullbulk, *nullmultibulk,
|
||||||
@ -633,6 +639,12 @@ static void redisLog(int level, const char *fmt, ...) {
|
|||||||
* keys and radis objects as values (objects can hold SDS strings,
|
* keys and radis objects as values (objects can hold SDS strings,
|
||||||
* lists, sets). */
|
* lists, sets). */
|
||||||
|
|
||||||
|
static void dictVanillaFree(void *privdata, void *val)
|
||||||
|
{
|
||||||
|
DICT_NOTUSED(privdata);
|
||||||
|
zfree(val);
|
||||||
|
}
|
||||||
|
|
||||||
static int sdsDictKeyCompare(void *privdata, const void *key1,
|
static int sdsDictKeyCompare(void *privdata, const void *key1,
|
||||||
const void *key2)
|
const void *key2)
|
||||||
{
|
{
|
||||||
@ -709,6 +721,15 @@ static dictType setDictType = {
|
|||||||
NULL /* val destructor */
|
NULL /* val destructor */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static dictType zsetDictType = {
|
||||||
|
dictEncObjHash, /* hash function */
|
||||||
|
NULL, /* key dup */
|
||||||
|
NULL, /* val dup */
|
||||||
|
dictEncObjKeyCompare, /* key compare */
|
||||||
|
dictRedisObjectDestructor, /* key destructor */
|
||||||
|
dictVanillaFree /* val destructor */
|
||||||
|
};
|
||||||
|
|
||||||
static dictType hashDictType = {
|
static dictType hashDictType = {
|
||||||
dictObjHash, /* hash function */
|
dictObjHash, /* hash function */
|
||||||
NULL, /* key dup */
|
NULL, /* key dup */
|
||||||
@ -1810,6 +1831,12 @@ static robj *createSetObject(void) {
|
|||||||
return createObject(REDIS_SET,d);
|
return createObject(REDIS_SET,d);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static robj *createZsetObject(void) {
|
||||||
|
dict *d = dictCreate(&zsetDictType,NULL);
|
||||||
|
if (!d) oom("dictCreate");
|
||||||
|
return createObject(REDIS_ZSET,d);
|
||||||
|
}
|
||||||
|
|
||||||
static void freeStringObject(robj *o) {
|
static void freeStringObject(robj *o) {
|
||||||
if (o->encoding == REDIS_ENCODING_RAW) {
|
if (o->encoding == REDIS_ENCODING_RAW) {
|
||||||
sdsfree(o->ptr);
|
sdsfree(o->ptr);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user