Commit 0e83bab6 authored by Petr Pudlak's avatar Petr Pudlak

Merge branch 'stable-2.9' into stable-2.10

* stable-2.9
  Ganeti.Daemon: always install SIGHUP handler
Signed-off-by: default avatarPetr Pudlak <pudlak@google.com>
Reviewed-by: default avatarKlaus Aehlig <aehlig@google.com>
parents 6e06de4e fef5c09e
......@@ -365,7 +365,6 @@ daemonize logfile action = do
setupDaemonEnv "/" (unionFileModes groupModes otherModes)
setupDaemonFDs (Just logfile) `Control.Exception.catch`
handlePrepErr False wpipe'
_ <- installHandler lostConnection (Catch (handleSigHup logfile)) Nothing
-- second fork, launches the actual child code; standard
-- double-fork technique
_ <- forkProcess (action wpipe')
......@@ -416,6 +415,7 @@ genericMain daemon options check_fn prep_fn exec_fn = do
let processFn = if optDaemonize opts
then daemonize log_file
else \action -> action Nothing
_ <- installHandler lostConnection (Catch (handleSigHup log_file)) Nothing
processFn $ innerMain daemon opts syslog check_result' prep_fn exec_fn
-- | Full prepare function.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment