From 78782ed59f107c7819440ca1f63dc3adb97ce4c1 Mon Sep 17 00:00:00 2001 From: Matt Stancliff Date: Mon, 24 Mar 2014 14:39:26 -0400 Subject: [PATCH] Use LRU_CLOCK() instead of function getLRUClock() lookupKey() uses LRU_CLOCK(), so it seems object creation should use LRU_CLOCK() too. --- src/object.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/object.c b/src/object.c index 22ffdd16..c6c1778f 100644 --- a/src/object.c +++ b/src/object.c @@ -40,7 +40,7 @@ robj *createObject(int type, void *ptr) { o->refcount = 1; /* Set the LRU to the current lruclock (minutes resolution). */ - o->lru = getLRUClock(); + o->lru = LRU_CLOCK(); return o; } @@ -61,7 +61,7 @@ robj *createEmbeddedStringObject(char *ptr, size_t len) { o->encoding = REDIS_ENCODING_EMBSTR; o->ptr = sh+1; o->refcount = 1; - o->lru = getLRUClock(); + o->lru = LRU_CLOCK(); sh->len = len; sh->free = 0;