diff table.c @ 2:ec2f8f6f1dc9

Cleanup pass #1: Get rid of some ancient K&R-isms.
author Matti Hamalainen <ccr@tnsp.org>
date Tue, 24 Feb 2015 20:28:57 +0200
parents 4410c9c7750d
children a2a81589380d
line wrap: on
line diff
--- a/table.c	Tue Feb 24 18:54:50 2015 +0200
+++ b/table.c	Tue Feb 24 20:28:57 2015 +0200
@@ -37,16 +37,9 @@
 
 static unsigned int firstunused = 0;
 
-#ifndef __STDC__
-table *
-FindNextEntryType (entry, andmask, eormask)
-     table *entry;
-     unsigned char andmask;
-     unsigned char eormask;
-#else
+
 table *FindNextEntryType (table *entry, unsigned char andmask,
                           unsigned char eormask)
-#endif
 {
   if (!scantable) return NULL;
 
@@ -62,17 +55,9 @@
   return NULL;
 }
 
-#ifndef __STDC__
-table *
-FindNextEntryTypeParent (entry, parent, andmask, eormask)
-     table *entry;
-     ADDR_T parent;
-     unsigned char andmask;
-     unsigned char eormask;
-#else
+
 table *FindNextEntryTypeParent (table *entry, ADDR_T parent,
                             unsigned char andmask, unsigned char eormask)
-#endif
 {
   if (!scantable) return NULL;
 
@@ -90,17 +75,9 @@
   return NULL;
 }
 
-#ifndef __STDC__
-table *
-FindNextEntry (entry, address, andmask, eormask)
-     table *entry;
-     ADDR_T address;
-     unsigned char andmask;
-     unsigned char eormask;
-#else
+
 table *FindNextEntry (table *entry, ADDR_T address,
                       unsigned char andmask, unsigned char eormask)
-#endif
 {
   if (!scantable) return NULL;
 
@@ -117,15 +94,8 @@
   return NULL;
 }
 
-#ifndef __STDC__
-void
-AddEntry (address, parent, type)
-     ADDR_T address;
-     ADDR_T parent;
-     unsigned char type;
-#else
+
 void AddEntry (ADDR_T address, ADDR_T parent, unsigned char type)
-#endif
 {
   if (firstunused < entrycount) {
     scantable[firstunused].address = address;
@@ -147,13 +117,8 @@
   }
 }
 
-#ifndef __STDC__
-void
-DeleteEntry (entry)
-     table *entry;
-#else
+
 void DeleteEntry (table *entry)
-#endif
 {
   entry -> type = TBL_DELETED;