From 99c293a4031c780a9c1dc3a1a7340eb53faf59b3 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Fri, 26 Jun 2020 13:05:56 +0100 Subject: [PATCH] log: fix --use-json-log going to stderr not --log-file on Windows - fixes #4367 --- fs/log/log.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/log/log.go b/fs/log/log.go index 3dbea6993..48c0bd45a 100644 --- a/fs/log/log.go +++ b/fs/log/log.go @@ -10,6 +10,7 @@ import ( "strings" "github.com/rclone/rclone/fs" + "github.com/sirupsen/logrus" ) // Options contains options for the remote control server @@ -120,6 +121,7 @@ func InitLogging() { fs.Errorf(nil, "Failed to seek log file to end: %v", err) } log.SetOutput(f) + logrus.SetOutput(f) redirectStderr(f) }