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
7ddbfd12
Commit
7ddbfd12
authored
Feb 06, 2015
by
Sun He
Committed by
antirez
Feb 08, 2015
Browse files
dict.c/dictRehash: check again to update
parent
17fa6b08
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/dict.c
View file @
7ddbfd12
...
...
@@ -282,6 +282,13 @@ int dictRehash(dict *d, int n) {
d
->
ht
[
0
].
table
[
d
->
rehashidx
]
=
NULL
;
d
->
rehashidx
++
;
}
/* Check again if we already rehashed the whole table... */
if
(
d
->
ht
[
0
].
used
==
0
)
{
zfree
(
d
->
ht
[
0
].
table
);
d
->
ht
[
0
]
=
d
->
ht
[
1
];
_dictReset
(
&
d
->
ht
[
1
]);
d
->
rehashidx
=
-
1
;
}
return
1
;
}
...
...
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