summaryrefslogtreecommitdiffstats
path: root/sbin/rcorder/hash.c
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2009-12-29 22:53:27 +0000
committered <ed@FreeBSD.org>2009-12-29 22:53:27 +0000
commitb9ca89bfc495774b5fe49e23a272c721c840f68b (patch)
tree2e35e76a520e919173f604f9ba0f30358443ed4a /sbin/rcorder/hash.c
parent86ca9a5a9bdaa4a662de58157f311ce58029b75a (diff)
downloadFreeBSD-src-b9ca89bfc495774b5fe49e23a272c721c840f68b.zip
FreeBSD-src-b9ca89bfc495774b5fe49e23a272c721c840f68b.tar.gz
ANSIfy almost all applications that use WARNS=6.
I was considering committing all these patches one by one, but as discussed with brooks@, there is no need to do this. If we ever need/want to merge these changes back, it is still possible to do this per application.
Diffstat (limited to 'sbin/rcorder/hash.c')
-rw-r--r--sbin/rcorder/hash.c40
1 files changed, 18 insertions, 22 deletions
diff --git a/sbin/rcorder/hash.c b/sbin/rcorder/hash.c
index bc882b9..34b95ce 100644
--- a/sbin/rcorder/hash.c
+++ b/sbin/rcorder/hash.c
@@ -103,9 +103,9 @@ static void RebuildTable(Hash_Table *);
*/
void
-Hash_InitTable(t, numBuckets)
- register Hash_Table *t; /* Structure to use to hold table. */
- int numBuckets; /* How many buckets to create for starters.
+Hash_InitTable(
+ register Hash_Table *t, /* Structure to use to hold table. */
+ int numBuckets) /* How many buckets to create for starters.
* This number is rounded up to a power of
* two. If <= 0, a reasonable default is
* chosen. The table will grow in size later
@@ -150,8 +150,7 @@ Hash_InitTable(t, numBuckets)
*/
void
-Hash_DeleteTable(t)
- Hash_Table *t;
+Hash_DeleteTable(Hash_Table *t)
{
register struct Hash_Entry **hp, *h, *nexth = NULL;
register int i;
@@ -190,9 +189,9 @@ Hash_DeleteTable(t)
*/
Hash_Entry *
-Hash_FindEntry(t, key)
- Hash_Table *t; /* Hash table to search. */
- char *key; /* A hash key. */
+Hash_FindEntry(
+ Hash_Table *t, /* Hash table to search. */
+ char *key) /* A hash key. */
{
register Hash_Entry *e;
register unsigned h;
@@ -227,10 +226,10 @@ Hash_FindEntry(t, key)
*/
Hash_Entry *
-Hash_CreateEntry(t, key, newPtr)
- register Hash_Table *t; /* Hash table to search. */
- char *key; /* A hash key. */
- Boolean *newPtr; /* Filled in with TRUE if new entry created,
+Hash_CreateEntry(
+ register Hash_Table *t, /* Hash table to search. */
+ char *key, /* A hash key. */
+ Boolean *newPtr) /* Filled in with TRUE if new entry created,
* FALSE otherwise. */
{
register Hash_Entry *e;
@@ -294,9 +293,7 @@ Hash_CreateEntry(t, key, newPtr)
*/
void
-Hash_DeleteEntry(t, e)
- Hash_Table *t;
- Hash_Entry *e;
+Hash_DeleteEntry(Hash_Table *t, Hash_Entry *e)
{
register Hash_Entry **hp, *p;
@@ -335,9 +332,9 @@ Hash_DeleteEntry(t, e)
*/
Hash_Entry *
-Hash_EnumFirst(t, searchPtr)
- Hash_Table *t; /* Table to be searched. */
- register Hash_Search *searchPtr;/* Area in which to keep state
+Hash_EnumFirst(
+ Hash_Table *t, /* Table to be searched. */
+ register Hash_Search *searchPtr)/* Area in which to keep state
* about search.*/
{
searchPtr->tablePtr = t;
@@ -365,8 +362,8 @@ Hash_EnumFirst(t, searchPtr)
*/
Hash_Entry *
-Hash_EnumNext(searchPtr)
- register Hash_Search *searchPtr; /* Area used to keep state about
+Hash_EnumNext(
+ register Hash_Search *searchPtr) /* Area used to keep state about
search. */
{
register Hash_Entry *e;
@@ -411,8 +408,7 @@ Hash_EnumNext(searchPtr)
*/
static void
-RebuildTable(t)
- register Hash_Table *t;
+RebuildTable(register Hash_Table *t)
{
register Hash_Entry *e, *next = NULL, **hp, **xp;
register int i, mask;
OpenPOWER on IntegriCloud