mirror of
https://github.com/fluencelabs/redis
synced 2025-06-16 18:51:20 +00:00
Regression tests for SETNX and MSETNX bugs added
This commit is contained in:
2
redis.c
2
redis.c
@ -2978,7 +2978,7 @@ static void echoCommand(redisClient *c) {
|
||||
static void setGenericCommand(redisClient *c, int nx) {
|
||||
int retval;
|
||||
|
||||
lookupKeyWrite(c->db,c->argv[1]);
|
||||
deleteIfVolatile(c->db,c->argv[1]);
|
||||
retval = dictAdd(c->db->dict,c->argv[1],c->argv[2]);
|
||||
if (retval == DICT_ERR) {
|
||||
if (!nx) {
|
||||
|
Reference in New Issue
Block a user