From: Josh Date: Thu, 25 Sep 2014 17:11:40 +0000 (-0400) Subject: fixing Modules X-Git-Tag: 3.0.0-233~1398^2~8^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06dd0a6732880ce9b96e74282d57abbf68f27aca;p=thirdparty%2Fsnort3.git fixing Modules --- diff --git a/src/main/modules.cc b/src/main/modules.cc index f2f1c89fa..83abb8795 100644 --- a/src/main/modules.cc +++ b/src/main/modules.cc @@ -1803,9 +1803,6 @@ bool HostsModule::begin(const char* fqn, int idx, SnortConfig*) else if ( idx && !strcmp(fqn, "hosts") ) host = SFAT_CreateHostEntry(); - else - return false; - return true; } @@ -1821,8 +1818,6 @@ bool HostsModule::end(const char* fqn, int idx, SnortConfig*) SFAT_AddHost(host); host = nullptr; } - else - return false; return true; } diff --git a/src/stream/tcp/tcp_module.cc b/src/stream/tcp/tcp_module.cc index f5eceba69..539309cd9 100644 --- a/src/stream/tcp/tcp_module.cc +++ b/src/stream/tcp/tcp_module.cc @@ -311,13 +311,18 @@ bool StreamTcpModule::set(const char*, Value& v, SnortConfig*) return true; } -bool StreamTcpModule::begin(const char*, int, SnortConfig*) +bool StreamTcpModule::begin(const char* fqn, int, SnortConfig*) { + if ( !strcmp(fqn, "stream_tcp.small_segments") || + !strcmp(fqn, "stream_tcp.queue_limit")) + { + return true; + } + if ( config ) return false; config = new StreamTcpConfig; - return true; }