summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2010-10-11 17:11:00 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2010-10-11 17:11:00 +0200
commit8c3d40b798e3ed68fb03629d87b55140cb6bc044 (patch)
treeb6320896b01d58c083e82a0b5c22e13240dcc6f2 /plugins
parented324a9a610f91f54514eb713ff5593bde1012e6 (diff)
downloadrsyslog-8c3d40b798e3ed68fb03629d87b55140cb6bc044.tar.gz
rsyslog-8c3d40b798e3ed68fb03629d87b55140cb6bc044.tar.xz
rsyslog-8c3d40b798e3ed68fb03629d87b55140cb6bc044.zip
removed need for math library
by doing math a little bit more optimal in hash table code. Also reduced memory requirement for imuxsock hash tables (expected number of connections was set too high -- table can be extended dynamically).
Diffstat (limited to 'plugins')
-rw-r--r--plugins/imuxsock/imuxsock.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/imuxsock/imuxsock.c b/plugins/imuxsock/imuxsock.c
index 566dde1b..0eee1122 100644
--- a/plugins/imuxsock/imuxsock.c
+++ b/plugins/imuxsock/imuxsock.c
@@ -283,7 +283,7 @@ addLstnSocketName(void __attribute__((unused)) *pVal, uchar *pNewVal)
}
CHKiRet(prop.ConstructFinalize(listeners[nfd].hostName));
if(ratelimitInterval > 0) {
- if((listeners[nfd].ht = create_hashtable(1000, hash_from_key_fn, key_equals_fn, NULL)) == NULL) {
+ if((listeners[nfd].ht = create_hashtable(100, hash_from_key_fn, key_equals_fn, NULL)) == NULL) {
/* in this case, we simply turn of rate-limiting */
dbgprintf("imuxsock: turning off rate limiting because we could not "
"create hash table\n");
@@ -761,7 +761,7 @@ CODESTARTwillRun
if(pLogSockName != NULL)
listeners[0].sockName = pLogSockName;
if(ratelimitIntervalSysSock > 0) {
- if((listeners[0].ht = create_hashtable(1000, hash_from_key_fn, key_equals_fn, NULL)) == NULL) {
+ if((listeners[0].ht = create_hashtable(100, hash_from_key_fn, key_equals_fn, NULL)) == NULL) {
/* in this case, we simply turn of rate-limiting */
dbgprintf("imuxsock: turning off rate limiting because we could not "
"create hash table\n");