Initialize more stuff before daemonizing so we exit properly on fatal errors
git-svn-id: https://svn.musicpd.org/mpd/trunk@4421 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
parent
688166295a
commit
95af15ce8f
@ -358,6 +358,8 @@ static void startMainProcess(void)
|
|||||||
/* we're killed */
|
/* we're killed */
|
||||||
playerKill();
|
playerKill();
|
||||||
|
|
||||||
|
finishPlaylist();
|
||||||
|
|
||||||
finishAudioConfig();
|
finishAudioConfig();
|
||||||
finishAudioDriver();
|
finishAudioDriver();
|
||||||
|
|
||||||
@ -546,12 +548,13 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
initPlayerData();
|
initPlayerData();
|
||||||
|
|
||||||
daemonize(&options);
|
|
||||||
|
|
||||||
initInputPlugins();
|
initInputPlugins();
|
||||||
initPaths();
|
initPaths();
|
||||||
initAudioConfig();
|
initAudioConfig();
|
||||||
initAudioDriver();
|
initAudioDriver();
|
||||||
|
initPlaylist();
|
||||||
|
|
||||||
|
daemonize(&options);
|
||||||
|
|
||||||
initSigHandlers();
|
initSigHandlers();
|
||||||
setupLogOutput(&options, out, err);
|
setupLogOutput(&options, out, err);
|
||||||
@ -562,8 +565,6 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
initPermissions();
|
initPermissions();
|
||||||
|
|
||||||
initPlaylist();
|
|
||||||
|
|
||||||
openDB(&options, argv[0]);
|
openDB(&options, argv[0]);
|
||||||
|
|
||||||
initCommands();
|
initCommands();
|
||||||
|
Loading…
Reference in New Issue
Block a user