DB API refactoring. The changes were designed together with Pieter Noordhuis.

This commit is contained in:
antirez
2011-06-14 15:34:27 +02:00
parent 3e2a0bf44a
commit f85cd526c1
7 changed files with 75 additions and 81 deletions

View File

@ -366,12 +366,12 @@ void sortCommand(redisClient *c) {
}
}
}
dbReplace(c->db,storekey,sobj);
setKey(c->db,storekey,sobj);
decrRefCount(sobj);
/* Note: we add 1 because the DB is dirty anyway since even if the
* SORT result is empty a new key is set and maybe the old content
* replaced. */
server.dirty += 1+outputlen;
signalModifiedKey(c->db,storekey);
addReplyLongLong(c,outputlen);
}