mirror of
https://github.com/fluencelabs/redis
synced 2025-06-12 08:41:21 +00:00
Use existing reply functions where possible
This commit is contained in:
6
src/db.c
6
src/db.c
@ -245,13 +245,11 @@ void keysCommand(redisClient *c) {
|
||||
}
|
||||
|
||||
void dbsizeCommand(redisClient *c) {
|
||||
addReplySds(c,
|
||||
sdscatprintf(sdsempty(),":%lu\r\n",dictSize(c->db->dict)));
|
||||
addReplyLongLong(c,dictSize(c->db->dict));
|
||||
}
|
||||
|
||||
void lastsaveCommand(redisClient *c) {
|
||||
addReplySds(c,
|
||||
sdscatprintf(sdsempty(),":%lu\r\n",server.lastsave));
|
||||
addReplyLongLong(c,server.lastsave);
|
||||
}
|
||||
|
||||
void typeCommand(redisClient *c) {
|
||||
|
Reference in New Issue
Block a user