X-Git-Url: https://git.saurik.com/redis.git/blobdiff_plain/f2923becc6cb11dc5cd979ad72a32d1801560df4..e6cca5dba6ad046625c195c9c4f39c7ce06ad080:/dict.h diff --git a/dict.h b/dict.h index 90d46f48..3a8e9b0b 100644 --- a/dict.h +++ b/dict.h @@ -5,7 +5,7 @@ * tables of power of two in size are used, collisions are handled by * chaining. See the source code for more information... :) * - * Copyright (c) 2006-2009, Salvatore Sanfilippo + * Copyright (c) 2006-2010, Salvatore Sanfilippo * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -73,7 +73,7 @@ typedef struct dictIterator { } dictIterator; /* This is the initial size of every hash table */ -#define DICT_HT_INITIAL_SIZE 16 +#define DICT_HT_INITIAL_SIZE 4 /* ------------------------------- Macros ------------------------------------*/ #define dictFreeEntryVal(ht, entry) \ @@ -127,6 +127,8 @@ dictEntry *dictGetRandomKey(dict *ht); void dictPrintStats(dict *ht); unsigned int dictGenHashFunction(const unsigned char *buf, int len); void dictEmpty(dict *ht); +void dictEnableResize(void); +void dictDisableResize(void); /* Hash table types */ extern dictType dictTypeHeapStringCopyKey;