]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
fixed flow warnings
authorJoel Cornett <joel.cornett@gmail.com>
Wed, 6 Apr 2016 19:02:33 +0000 (15:02 -0400)
committerJoel Cornett <joel.cornett@gmail.com>
Wed, 6 Apr 2016 19:02:33 +0000 (15:02 -0400)
src/flow/flow_control.cc
src/flow/flow_control.h

index 029b7d6fa229f7fcda1c92f15a1d6695c961e459..9aa1a507dc20d31fea85477a2e722a0efa3d2386 100644 (file)
@@ -296,10 +296,10 @@ void FlowControl::timeout_flows(uint32_t flowCount, time_t cur_time)
     Active::resume();
 }
 
-void FlowControl::preemptive_cleanup(const Packet* p)
+void FlowControl::preemptive_cleanup()
 {
     DebugFormat(DEBUG_FLOW, "doing preemptive cleanup for packet of type %d",
-            static_cast<int>(p->type()));
+            last_pkt_type);
 
     // FIXIT-L J is there a possibility of this looping forever?
     while ( memory::MemoryCap::over_threshold() )
@@ -465,8 +465,7 @@ unsigned FlowControl::process(Flow* flow, Packet* p)
     p->disable_inspect = flow->is_inspection_disabled();
 
     last_pkt_type = p->type();
-
-    preemptive_cleanup(p);
+    preemptive_cleanup();
 
     if ( flow->flow_state )
         set_policies(snort_conf, flow->policy_id);
index c8e4366d3d832e9a041d9cc7a00fe9d595c5f111..70600743a371f7e3710881830a0503158080dd16 100644 (file)
@@ -103,7 +103,7 @@ private:
     void set_key(FlowKey*, Packet*);
 
     unsigned process(Flow*, Packet*);
-    void preemptive_cleanup(const Packet*);
+    void preemptive_cleanup();
 
 private:
     FlowCache* ip_cache;