aboutsummaryrefslogtreecommitdiffstats
path: root/hashlib.c
diff options
context:
space:
mode:
authorJari Aalto <jari.aalto@cante.net>1999-02-19 17:11:39 +0000
committerJari Aalto <jari.aalto@cante.net>2009-09-12 16:46:52 +0000
commitb72432fdcc59300c6fe7c9d6c8a31ad3447933f5 (patch)
treeb9899162338c2ff3fd83a8aef8831cb119e85cd7 /hashlib.c
parentbc4cd23ce958feda898c618215f94d8a4e8f4ffa (diff)
downloadandroid_external_bash-b72432fdcc59300c6fe7c9d6c8a31ad3447933f5.tar.gz
android_external_bash-b72432fdcc59300c6fe7c9d6c8a31ad3447933f5.tar.bz2
android_external_bash-b72432fdcc59300c6fe7c9d6c8a31ad3447933f5.zip
Imported from ../bash-2.03.tar.gz.
Diffstat (limited to 'hashlib.c')
-rw-r--r--hashlib.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/hashlib.c b/hashlib.c
index e370fbe..b9cf95b 100644
--- a/hashlib.c
+++ b/hashlib.c
@@ -67,6 +67,9 @@ make_hash_table (buckets)
/* Return the location of the bucket which should contain the data
for STRING. TABLE is a pointer to a HASH_TABLE. */
+/* A possibly better distribution may be obtained by initializing i to
+ ~0UL and using i = (i * 33) + *string++ as the step */
+
#define ALL_ONES (~((unsigned long) 0))
#define BITS(h, n) ((unsigned long)(h) & ~(ALL_ONES << (n)))