Loading...
db/hash/FreeBSD/hash_func.c Libc-1725.40.4 Libc-583
--- Libc/Libc-1725.40.4/db/hash/FreeBSD/hash_func.c
+++ Libc/Libc-583/db/hash/FreeBSD/hash_func.c
@@ -13,6 +13,10 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ *    must display the following acknowledgement:
+ *	This product includes software developed by the University of
+ *	California, Berkeley and its contributors.
  * 4. Neither the name of the University nor the names of its contributors
  *    may be used to endorse or promote products derived from this software
  *    without specific prior written permission.
@@ -34,14 +38,14 @@
 static char sccsid[] = "@(#)hash_func.c	8.2 (Berkeley) 2/21/94";
 #endif /* LIBC_SCCS and not lint */
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/libc/db/hash/hash_func.c,v 1.6 2007/01/09 00:27:50 imp Exp $");
+__FBSDID("$FreeBSD: src/lib/libc/db/hash/hash_func.c,v 1.5 2003/02/16 17:29:09 nectar Exp $");
 
 #include <sys/types.h>
 
 #include <db.h>
 #include "hash.h"
 #include "page.h"
-#include "hash_extern.h"
+#include "extern.h"
 
 static u_int32_t hash1(const void *, size_t) __unused;
 static u_int32_t hash2(const void *, size_t) __unused;
@@ -64,7 +68,9 @@
 #define PRIME2		1048583
 
 static u_int32_t
-hash1(const void *keyarg, size_t len)
+hash1(keyarg, len)
+	const void *keyarg;
+	size_t len;
 {
 	const u_char *key;
 	u_int32_t h;
@@ -82,7 +88,9 @@
 #define dcharhash(h, c)	((h) = 0x63c63cd9*(h) + 0x9c39c33d + (c))
 
 static u_int32_t
-hash2(const void *keyarg, size_t len)
+hash2(keyarg, len)
+	const void *keyarg;
+	size_t len;
 {
 	const u_char *e, *key;
 	u_int32_t h;
@@ -109,7 +117,9 @@
  * OZ's original sdbm hash
  */
 static u_int32_t
-hash3(const void *keyarg, size_t len)
+hash3(keyarg, len)
+	const void *keyarg;
+	size_t len;
 {
 	const u_char *key;
 	size_t loop;
@@ -155,7 +165,9 @@
 
 /* Hash function from Chris Torek. */
 static u_int32_t
-hash4(const void *keyarg, size_t len)
+hash4(keyarg, len)
+	const void *keyarg;
+	size_t len;
 {
 	const u_char *key;
 	size_t loop;