listen: moved redirect_stdin() to daemon.c

redirect_stdin() is a daemonization function, and disconnecting from
the standard input is always a good idea for MPD.
This commit is contained in:
Max Kellermann
2008-12-30 16:28:13 +01:00
parent 671480814c
commit 6c0f5fc612
4 changed files with 34 additions and 29 deletions

View File

@@ -186,6 +186,8 @@ int main(int argc, char *argv[])
clock_t start;
GTimer *save_state_timer;
daemonize_close_stdin();
#ifdef HAVE_LOCALE
/* initialize locale */
setlocale(LC_CTYPE,"");