Lots of changes. In no particular order:
[distributedratelimiting.git] / drl / standard.h
index d54aa3e..27a3d8c 100644 (file)
 #include <inttypes.h>
 
 /** The number of hash buckets in the table. */
-#define FLOW_HASH_SIZE 1024
+#define STD_FLOW_HASH_SIZE 1024
 
 /** The number of seconds after which a flow is considered to be inactive.
  * Inactive flows will be removed from the table during the next call to the
  * cleanup function. */
-#define FLOW_IDLE_TIME 15
+#define STD_FLOW_IDLE_TIME 15
 
 /** Representation of a flow in a standard table. */
 typedef struct std_flow {
@@ -86,7 +86,7 @@ struct std_flow_table {
     /* Table structures. */
 
     /** Hash buckets - each is a list of flows. */
-    struct std_flow *flows[FLOW_HASH_SIZE];
+    struct std_flow *flows[STD_FLOW_HASH_SIZE];
 
     /** The head of the linked list of flows. */
     struct std_flow *flows_head;
@@ -137,7 +137,7 @@ int standard_table_sample(standard_flow_table table, const key_flow *key);
 
 /**
  * Cleans the table by removing flow entires for any flow that hasn't seen a
- * new packet in the interval specified by FLOW_IDLE_TIME seconds.
+ * new packet in the interval specified by STD_FLOW_IDLE_TIME seconds.
  */
 int standard_table_cleanup(standard_flow_table table);