From 547ddf42648e55b3235343ac7d4eae27931362f8 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Sun, 26 Jun 2016 23:30:22 +0200 Subject: tlog: switch default logger to syslog ...unless "-nosyslog" is passed. All gocryptfs messages already go to syslog, but the messages that the go-fuse lib emits were still printed to stdout. Fixes issue #13 ( https://github.com/rfjakob/gocryptfs/issues/13 ) --- internal/tlog/log_go1.4.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'internal/tlog/log_go1.4.go') diff --git a/internal/tlog/log_go1.4.go b/internal/tlog/log_go1.4.go index fae0e9b..98d69db 100644 --- a/internal/tlog/log_go1.4.go +++ b/internal/tlog/log_go1.4.go @@ -8,5 +8,9 @@ import ( ) func (l *toggledLogger) SwitchToSyslog(p syslog.Priority) { - Debug.Printf("Cannot switch to syslog - need Go 1.5 or higher") + Info.Printf("Cannot switch to syslog - need Go 1.5 or higher") +} + +func SwitchLoggerToSyslog(p syslog.Priority) { + Info.Printf("Cannot switch to syslog - need Go 1.5 or higher") } -- cgit v1.2.3