]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Merge pull request #1201 in SNORT/snort3 from fixed_ip4_id to master
authorRuss Combs (rucombs) <rucombs@cisco.com>
Wed, 25 Apr 2018 10:42:18 +0000 (06:42 -0400)
committerRuss Combs (rucombs) <rucombs@cisco.com>
Wed, 25 Apr 2018 10:42:18 +0000 (06:42 -0400)
Squashed commit of the following:

commit 67252ea2a66b113a98f2c2c3239ef21d0713d30c
Author: Steven Baigal (sbaigal) <sbaigal@cisco.com>
Date:   Tue Apr 24 14:41:38 2018 -0400

    ip: replaced REG_TEST with -H option for ipv4 codec fixed seed

src/codecs/ip/cd_ipv4.cc

index 99900c68655595be2388911e6af835763ef77dcf..4754f5ce7768a487dadb1996f8ea6a15c2fb1f51 100644 (file)
@@ -736,9 +736,8 @@ static void ipv4_codec_tinit()
     std::random_device rd; // for a good seed
     auto id = rd();
 
-#ifdef REG_TEST
-    id = 1;
-#endif
+    if (SnortConfig::static_hash())
+        id = 1;
 
     thread_rand = new std::mt19937(id);
 }