Merge remote-tracking branch 'seehuhn/1.1' into 1.1
authorGuus Sliepen <guus@tinc-vpn.org>
Sat, 14 Mar 2015 11:45:55 +0000 (11:45 +0000)
committerGuus Sliepen <guus@tinc-vpn.org>
Sat, 14 Mar 2015 11:45:55 +0000 (11:45 +0000)
1  2 
src/process.c
src/tincd.c

diff --cc src/process.c
index 2243bf9c46c46b569d404f4af2b79e73f4bc69a5,86953adccf60cc05c09e36e435612696cd1776c7..2dab2b58b2e1a84e86b6e80d8f8a609e12f1d8eb
@@@ -210,10 -209,13 +213,13 @@@ bool detach(void) 
  #endif
        }
  
-       openlogger(identname, use_logfile?LOGMODE_FILE:(do_detach?LOGMODE_SYSLOG:LOGMODE_STDERR));
+       logmode = use_logfile?LOGMODE_FILE:LOGMODE_SYSLOG;
+       if(do_detach && !use_syslog)
+               logmode = LOGMODE_STDERR;
+       openlogger(identname, logmode);
  
        logger(DEBUG_ALWAYS, LOG_NOTICE, "tincd %s (%s %s) starting, debug level %d",
 -                         VERSION, __DATE__, __TIME__, debug_level);
 +                         VERSION, BUILD_DATE, BUILD_TIME, debug_level);
  
        return true;
  }
diff --cc src/tincd.c
Simple merge