Add missing shutdown/program state dumps for SIGUSR2 reload handler

Credits to @west0rmann finding the issue and providing the initial fix.

fixes #6689
fixes #6592
This commit is contained in:
Michael Friedrich 2018-10-16 11:54:14 +02:00
parent 3cccc9d9b8
commit af6c8a1f50
1 changed files with 7 additions and 0 deletions

View File

@ -751,6 +751,13 @@ void Application::SigUsr2Handler(int)
instance->ClosePidFile(false);
/* Ensure to dump the program state on reload. */
ConfigObject::StopObjects();
instance->OnShutdown();
Log(LogInformation, "Application")
<< "Reload done, parent process shutting down. Child process with PID '" << m_ReloadProcess << "' is taking over.";
Exit(0);
}