From: Shanmugam S (shanms) Date: Tue, 16 May 2023 06:31:14 +0000 (+0000) Subject: Pull request #3823: main: Disable watchdog when Snort 3 process exits gracefully X-Git-Tag: 3.1.62.0~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3731bff580ebadde22bf682acf83ce02367f9e89;p=thirdparty%2Fsnort3.git Pull request #3823: main: Disable watchdog when Snort 3 process exits gracefully Merge in SNORT/snort3 from ~AMUTTUVA/snort3:watchdog_quit_master to master Squashed commit of the following: commit 05fbd9ecb7a8225b8c573e90954ed0c343abed91 Author: Akhilesh MY Date: Tue Apr 25 02:03:45 2023 -0400 main: Disable watchdog when Snort 3 process exits gracefully --- diff --git a/src/main.cc b/src/main.cc index da07634e7..22345410b 100644 --- a/src/main.cc +++ b/src/main.cc @@ -731,6 +731,10 @@ int main_dump_plugins(lua_State*) int main_quit(lua_State* L) { ControlConn* ctrlcon = ControlConn::query_from_lua(L); + SnortConfig* sc = SnortConfig::get_main_conf(); + // Disable watchdog when process stops + if (sc) + sc->set_watchdog(0); send_response(ctrlcon, "== stopping\n"); main_broadcast_command(new ACStop(), ctrlcon); exit_requested = true;