From: rcombs Date: Wed, 12 Nov 2014 22:51:38 +0000 (-0500) Subject: suspend active when purging caches X-Git-Tag: 3.0.0-233~1228 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c416dcc8dfc6422ebbf6ad64f0523df5582cadd6;p=thirdparty%2Fsnort3.git suspend active when purging caches --- diff --git a/ChangeLog b/ChangeLog index ab9584afd..66cb1d5b9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -23,6 +23,7 @@ -- flush available data for non-paf splitters -- fixed inspector reinit -- fixed byte_extract and byte_jump endianisms +-- suspend active when purging caches 127 -- REG_TEST out logging tcp options for rebuilt packets to match snort bug diff --git a/src/flow/flow_cache.cc b/src/flow/flow_cache.cc index 5464213a2..7858da32c 100644 --- a/src/flow/flow_cache.cc +++ b/src/flow/flow_cache.cc @@ -313,6 +313,7 @@ int FlowCache::purge() { int retCount = 0; + Active_Suspend(); flags |= SESSION_CACHE_FLAG_PURGING; Flow* flow = (Flow*)hash_table->first(); @@ -325,6 +326,7 @@ int FlowCache::purge() } flags &= ~SESSION_CACHE_FLAG_PURGING; + Active_Resume(); return retCount; } diff --git a/src/main/snort.cc b/src/main/snort.cc index 04a8e6622..951464bd2 100644 --- a/src/main/snort.cc +++ b/src/main/snort.cc @@ -1003,6 +1003,7 @@ void snort_thread_term() DAQ_Delete(); + // FIXIT-L this is kinda squiffy for multithreads if ( snort_conf->dirty_pig ) return;