]> git.tue.mpg.de Git - paraslash.git/commitdiff
audiod.c: Don't log to /dev/null.
authorAndre Noll <maan@systemlinux.org>
Sun, 17 Feb 2008 20:52:21 +0000 (21:52 +0100)
committerAndre Noll <maan@systemlinux.org>
Sun, 17 Feb 2008 20:52:21 +0000 (21:52 +0100)
There's no point in computing the log message if we are
going to write it to /dev/null.

audiod.c

index dee31d5c5606727d1f320e1ad16abb09a0c6b97b..65343e5c26fed69375c25b7ae8a2ac26880dc6ab 100644 (file)
--- a/audiod.c
+++ b/audiod.c
@@ -144,6 +144,8 @@ void para_log(int ll, const char* fmt,...)
 
        if (ll < conf.loglevel_arg)
                return;
+       if (!logfile && conf.daemon_given)
+               return;
        if (!hostname)
                hostname = para_hostname();
        outfd = logfile? logfile : stderr;