summaryrefslogtreecommitdiff
path: root/src/plugins/irc/irc-config.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2013-01-26 19:26:43 +0100
committerSebastien Helleu <flashcode@flashtux.org>2013-01-26 19:26:43 +0100
commit25eaec3864a7ffe48b042057f8c07da26b676337 (patch)
tree05da43a9e66a6b1b4db6551689a61d8acc8cd21c /src/plugins/irc/irc-config.c
parentf4dce0472391432e8af4f2c0e39401d90cb86737 (diff)
downloadweechat-25eaec3864a7ffe48b042057f8c07da26b676337.zip
core: use size of 32 for hashtables (instead of 4, 8 or 16)
A size of 32 will use a little more memory but will reduce collisions in key hashs, and then length of linked lists inside hash structure (faster search in hashtable).
Diffstat (limited to 'src/plugins/irc/irc-config.c')
-rw-r--r--src/plugins/irc/irc-config.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/plugins/irc/irc-config.c b/src/plugins/irc/irc-config.c
index 7a801ab4f..eee061e2f 100644
--- a/src/plugins/irc/irc-config.c
+++ b/src/plugins/irc/irc-config.c
@@ -428,7 +428,7 @@ irc_config_change_look_nick_color_force (void *data,
if (!irc_config_hashtable_nick_color_force)
{
- irc_config_hashtable_nick_color_force = weechat_hashtable_new (8,
+ irc_config_hashtable_nick_color_force = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
@@ -581,7 +581,7 @@ irc_config_change_color_mirc_remap (void *data, struct t_config_option *option)
if (!irc_config_hashtable_color_mirc_remap)
{
- irc_config_hashtable_color_mirc_remap = weechat_hashtable_new (8,
+ irc_config_hashtable_color_mirc_remap = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
@@ -626,7 +626,7 @@ irc_config_change_color_nick_prefixes (void *data,
if (!irc_config_hashtable_nick_prefixes)
{
- irc_config_hashtable_nick_prefixes = weechat_hashtable_new (8,
+ irc_config_hashtable_nick_prefixes = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
@@ -1954,17 +1954,17 @@ irc_config_init ()
{
struct t_config_section *ptr_section;
- irc_config_hashtable_color_mirc_remap = weechat_hashtable_new (8,
+ irc_config_hashtable_color_mirc_remap = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
NULL);
- irc_config_hashtable_nick_color_force = weechat_hashtable_new (8,
+ irc_config_hashtable_nick_color_force = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
NULL);
- irc_config_hashtable_nick_prefixes = weechat_hashtable_new (8,
+ irc_config_hashtable_nick_prefixes = weechat_hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,