]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
suricata: expose system as global
authorVictor Julien <victor@inliniac.net>
Thu, 25 Apr 2019 14:52:41 +0000 (16:52 +0200)
committerVictor Julien <victor@inliniac.net>
Tue, 3 Sep 2019 13:17:55 +0000 (15:17 +0200)
src/suricata.c

index 33aeb51e946862834131a4d2cc6f75d4e7496fff..8f07df90132b97c81c7a26b9b00730919709534a 100644 (file)
@@ -223,6 +223,8 @@ int sc_set_caps = FALSE;
 /** highest mtu of the interfaces we monitor */
 int g_default_mtu = 0;
 
+bool g_system = false;
+
 /** disable randomness to get reproducible results accross runs */
 #ifndef AFLFUZZ_NO_RANDOM
 int g_disable_randomness = 0;
@@ -2125,7 +2127,7 @@ static TmEcode ParseCommandLine(int argc, char** argv, SCInstance *suri)
         suri->run_mode = RUNMODE_ENGINE_ANALYSIS;
 
     suri->offline = IsRunModeOffline(suri->run_mode);
-    suri->system = IsRunModeSystem(suri->run_mode);
+    g_system = suri->system = IsRunModeSystem(suri->run_mode);
 
     ret = SetBpfString(optind, argv);
     if (ret != TM_ECODE_OK)