Skip to content

Commit

Permalink
prepare to cherry pick variadic ZADD without conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
antirez committed May 31, 2011
1 parent 83533b6 commit 6e326c8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/t_zset.c
Expand Up @@ -859,7 +859,7 @@ void zaddGenericCommand(redisClient *c, int incr) {
zobj->ptr = zzlDelete(zobj->ptr,eptr);
zobj->ptr = zzlInsert(zobj->ptr,ele,score);

touchWatchedKey(c->db,key);
signalModifiedKey(c->db,key);
server.dirty++;
}

Expand All @@ -876,7 +876,7 @@ void zaddGenericCommand(redisClient *c, int incr) {
if (sdslen(ele->ptr) > server.zset_max_ziplist_value)
zsetConvert(zobj,REDIS_ENCODING_SKIPLIST);

touchWatchedKey(c->db,key);
signalModifiedKey(c->db,key);
server.dirty++;

if (incr) /* ZINCRBY */
Expand Down Expand Up @@ -914,7 +914,7 @@ void zaddGenericCommand(redisClient *c, int incr) {
incrRefCount(curobj); /* Re-inserted in skiplist. */
dictGetEntryVal(de) = &znode->score; /* Update score ptr. */

touchWatchedKey(c->db,key);
signalModifiedKey(c->db,key);
server.dirty++;
}

Expand All @@ -928,7 +928,7 @@ void zaddGenericCommand(redisClient *c, int incr) {
redisAssert(dictAdd(zs->dict,ele,&znode->score) == DICT_OK);
incrRefCount(ele); /* Added to dictionary. */

touchWatchedKey(c->db,key);
signalModifiedKey(c->db,key);
server.dirty++;

if (incr) /* ZINCRBY */
Expand Down

0 comments on commit 6e326c8

Please sign in to comment.