add batch-mode script
[IRC.git] / Robust / src / Runtime / chash.h
index 23a44247b1f4d60965bc047dbabc9a7b57e8e42d..ca256f22dda7f6caea4153bbb5581406c6d32876 100644 (file)
@@ -7,7 +7,7 @@
 //#define INLINE
 
 typedef struct cnode {
-  unsigned int key;
+  void * key;
   void *val;       //this can be cast to another type or used to point to a larger structure
   struct cnode *next;
   struct cnode *lnext;
@@ -25,9 +25,9 @@ typedef struct ctable {
 
 /* Prototypes for hash*/
 ctable_t *cCreate(unsigned int size, float loadfactor);
-void cInsert(ctable_t *table, unsigned int key, void * val);
-void * cSearch(ctable_t *table, unsigned int key); //returns val, NULL if not found
-unsigned int cRemove(ctable_t *table, unsigned int key); //returns -1 if not found
+void cInsert(ctable_t *table, void * key, void * val);
+void * cSearch(ctable_t *table, void * key); //returns val, NULL if not found
+unsigned int cRemove(ctable_t *table, void * key); //returns -1 if not found
 unsigned int cResize(ctable_t *table, unsigned int newsize);
 void cDelete(ctable_t *table);
 void crehash(ctable_t *table);