]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Merge pull request #1372 in SNORT/snort3 from nss_file_data_fix to master
authorMichael Altizer (mialtize) <mialtize@cisco.com>
Thu, 27 Sep 2018 13:40:56 +0000 (09:40 -0400)
committerMichael Altizer (mialtize) <mialtize@cisco.com>
Thu, 27 Sep 2018 13:40:56 +0000 (09:40 -0400)
Squashed commit of the following:

commit d0161f715422f7f32fdb40179c20018ad097940d
Author: Bhagya Tholpady <bbantwal@cisco.com>
Date:   Wed Sep 26 14:10:23 2018 -0400

    mime: made the mime hdr info and current search thread local

src/mime/file_mime_process.cc

index 633e9f58e57e552223727b7812383f9dce80117f..a21f8f74aaba75f9887d0693555ed452644c5b73 100644 (file)
@@ -69,11 +69,11 @@ struct MIMESearchInfo
     int length;
 };
 
-MIMESearchInfo mime_search_info;
+static THREAD_LOCAL MIMESearchInfo mime_search_info;
+static THREAD_LOCAL MIMESearch* mime_current_search = nullptr;
 
 SearchTool* mime_hdr_search_mpse = nullptr;
 MIMESearch mime_hdr_search[HDR_LAST];
-MIMESearch* mime_current_search = nullptr;
 
 static void get_mime_eol(const uint8_t* ptr, const uint8_t* end,
     const uint8_t** eol, const uint8_t** eolm)