unix-socket: fix alert metadata logging

This changeset fixes a bug that was preventing suricata to dump
alert metadata info when running in unix-socket mode.
When running in unix-socket mode, suricata was skipping the
initialization of the output modules and, as a consequence,
the metadata output module was never invoked.
pull/5533/head
Angelo Mirabella 6 years ago committed by Victor Julien
parent 62cc0c7acf
commit ea15282f47

@ -2032,11 +2032,12 @@ void PreRunInit(const int runmode)
* but after we dropped privs */ * but after we dropped privs */
void PreRunPostPrivsDropInit(const int runmode) void PreRunPostPrivsDropInit(const int runmode)
{ {
StatsSetupPostConfigPreOutput();
RunModeInitializeOutputs();
if (runmode == RUNMODE_UNIX_SOCKET) if (runmode == RUNMODE_UNIX_SOCKET)
return; return;
StatsSetupPostConfigPreOutput();
RunModeInitializeOutputs();
StatsSetupPostConfigPostOutput(); StatsSetupPostConfigPostOutput();
} }

Loading…
Cancel
Save