go.undefinedlabs.com/scopeagent@v0.4.2/instrumentation/logging/logger_go12.go (about) 1 // +build go1.12 2 // +build !go1.13 3 4 package logging 5 6 import ( 7 "io" 8 stdlog "log" 9 "os" 10 ) 11 12 // Gets the standard logger writer 13 func getStdLoggerWriter() io.Writer { 14 return os.Stderr // There is no way to get the current writer for the standard logger, but the default one is os.Stderr 15 } 16 17 // Gets the writer of a custom logger 18 func getLoggerWriter(logger *stdlog.Logger) io.Writer { 19 return logger.Writer() 20 }