mirror of https://mirror.osredm.com/root/redis.git
RESTORE ability to set a TTL fixed, bug introduced with millisecond expires.
This commit is contained in:
parent
a149ce6875
commit
70d848e1fa
|
@ -1577,7 +1577,7 @@ void restoreCommand(redisClient *c) {
|
||||||
|
|
||||||
/* Create the key and set the TTL if any */
|
/* Create the key and set the TTL if any */
|
||||||
dbAdd(c->db,c->argv[1],obj);
|
dbAdd(c->db,c->argv[1],obj);
|
||||||
if (ttl) setExpire(c->db,c->argv[1],time(NULL)+ttl);
|
if (ttl) setExpire(c->db,c->argv[1],mstime()+ttl);
|
||||||
signalModifiedKey(c->db,c->argv[1]);
|
signalModifiedKey(c->db,c->argv[1]);
|
||||||
addReply(c,shared.ok);
|
addReply(c,shared.ok);
|
||||||
server.dirty++;
|
server.dirty++;
|
||||||
|
|
Loading…
Reference in New Issue