projects
/
tinc
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
04fc191
)
Fix the case where we detach and use --logfile.
author
Guus Sliepen
<guus@tinc-vpn.org>
Sat, 14 Mar 2015 12:02:06 +0000
(12:02 +0000)
committer
Guus Sliepen
<guus@tinc-vpn.org>
Sat, 14 Mar 2015 12:02:06 +0000
(12:02 +0000)
src/process.c
patch
|
blob
|
history
diff --git
a/src/process.c
b/src/process.c
index
2dab2b5
..
51bd902
100644
(file)
--- a/
src/process.c
+++ b/
src/process.c
@@
-213,9
+213,13
@@
bool detach(void) {
#endif
}
- logmode = use_logfile?LOGMODE_FILE:LOGMODE_SYSLOG;
- if(do_detach && !use_syslog)
+ if(use_logfile)
+ logmode = LOGMODE_FILE;
+ else if(use_syslog || do_detach)
+ logmode = LOGMODE_SYSLOG;
+ else
logmode = LOGMODE_STDERR;
+
openlogger(identname, logmode);
logger(DEBUG_ALWAYS, LOG_NOTICE, "tincd %s (%s %s) starting, debug level %d",