Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
70d848e1
Commit
70d848e1
authored
Apr 02, 2012
by
antirez
Browse files
RESTORE ability to set a TTL fixed, bug introduced with millisecond expires.
parent
a149ce68
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/cluster.c
View file @
70d848e1
...
...
@@ -1577,7 +1577,7 @@ void restoreCommand(redisClient *c) {
/* Create the key and set the TTL if any */
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
],
ms
time
()
+
ttl
);
signalModifiedKey
(
c
->
db
,
c
->
argv
[
1
]);
addReply
(
c
,
shared
.
ok
);
server
.
dirty
++
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment