summaryrefslogtreecommitdiff
path: root/src/dict.c
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2014-08-13 11:44:38 +0200
committerantirez <antirez@gmail.com>2014-08-13 11:44:38 +0200
commitedca2b14d213c31da9e7a919f6b898f3ea8abea8 (patch)
tree4e4693dd041c259faec00b40a339157e33cac10e /src/dict.c
parent7e3ccddc6d728250dd473c1ab4348d899ab69eb3 (diff)
downloadredis-edca2b14d213c31da9e7a919f6b898f3ea8abea8.tar.gz
Remove warnings and improve integer sign correctness.
Diffstat (limited to 'src/dict.c')
-rw-r--r--src/dict.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/dict.c b/src/dict.c
index b27920a44..42e75fc22 100644
--- a/src/dict.c
+++ b/src/dict.c
@@ -668,9 +668,9 @@ dictEntry *dictGetRandomKey(dict *d)
* statistics. However the function is much faster than dictGetRandomKey()
* at producing N elements, and the elements are guaranteed to be non
* repeating. */
-int dictGetRandomKeys(dict *d, dictEntry **des, int count) {
+unsigned int dictGetRandomKeys(dict *d, dictEntry **des, unsigned int count) {
int j; /* internal hash table id, 0 or 1. */
- int stored = 0;
+ unsigned int stored = 0;
if (dictSize(d) < count) count = dictSize(d);
while(stored < count) {