diff --git a/Gopkg.lock b/Gopkg.lock index abef48fc..167ca188 100644 --- a/Gopkg.lock +++ b/Gopkg.lock @@ -65,10 +65,10 @@ revision = "0a025b7e63adc15a622f29b0b2c4c3848243bbf6" [[projects]] - branch = "master" name = "github.com/jedisct1/dlog" packages = ["."] - revision = "b9f8973c5e799516c1f20a25c2da985a4e86bf0a" + revision = "b4b1aa34ca8400126287cfab55c7931e8f37f7de" + version = "0.1" [[projects]] branch = "master" diff --git a/vendor/github.com/jedisct1/dlog/dlog.go b/vendor/github.com/jedisct1/dlog/dlog.go index 6d90a318..39a2251b 100644 --- a/vendor/github.com/jedisct1/dlog/dlog.go +++ b/vendor/github.com/jedisct1/dlog/dlog.go @@ -185,17 +185,15 @@ func logf(severity Severity, format string, args ...interface{}) { defer _globals.Unlock() if *_globals.useSyslog && _globals.systemLogger == nil { systemLogger, err := newSystemLogger(_globals.appName, _globals.syslogFacility) - if err != nil { - panic(err) + if err == nil { + _globals.systemLogger = systemLogger } - _globals.systemLogger = systemLogger } if _globals.fileName != nil && len(*_globals.fileName) > 0 && _globals.outFd == nil { outFd, err := os.OpenFile(*_globals.fileName, os.O_WRONLY|os.O_APPEND|os.O_CREATE, 0644) - if err != nil { - panic(err) + if err == nil { + _globals.outFd = outFd } - _globals.outFd = outFd } if _globals.systemLogger != nil { (*_globals.systemLogger).writeString(severity, message) diff --git a/vendor/github.com/jedisct1/dlog/sysdeps_windows.go b/vendor/github.com/jedisct1/dlog/sysdeps_windows.go index dd23606f..94664e47 100644 --- a/vendor/github.com/jedisct1/dlog/sysdeps_windows.go +++ b/vendor/github.com/jedisct1/dlog/sysdeps_windows.go @@ -7,11 +7,9 @@ type systemLogger struct { } func newSystemLogger(appName string, facility string) (*systemLogger, error) { - err := eventlog.InstallAsEventCreate(appName, eventlog.Error|eventlog.Warning|eventlog.Info) - if err != nil { - return nil, err - } + eventlog.InstallAsEventCreate(appName, eventlog.Error|eventlog.Warning|eventlog.Info) var eventLogger *eventlog.Log + var err error if eventLogger, err = eventlog.Open(appName); err != nil { return nil, err }