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
eb392c0a
Unverified
Commit
eb392c0a
authored
Nov 17, 2023
by
zhaozhao.zz
Committed by
GitHub
Nov 17, 2023
Browse files
replace calculateKeySlot with known slot in evictionPoolPopulate (#12777)
parent
6013122c
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/evict.c
View file @
eb392c0a
...
...
@@ -162,7 +162,7 @@ void evictionPoolPopulate(int dbid, int slot, dict *sampledict, redisDb *db, str
* dictionary (but the expires one) we need to lookup the key
* again in the key dictionary to obtain the value object. */
if
(
server
.
maxmemory_policy
!=
MAXMEMORY_VOLATILE_TTL
)
{
if
(
!
(
server
.
maxmemory_policy
&
MAXMEMORY_FLAG_ALLKEYS
))
de
=
dictFind
(
db
->
dict
[
calculateKeySlot
(
key
)
],
key
);
if
(
!
(
server
.
maxmemory_policy
&
MAXMEMORY_FLAG_ALLKEYS
))
de
=
dictFind
(
db
->
dict
[
slot
],
key
);
o
=
dictGetVal
(
de
);
}
...
...
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