diff options
author | Jakob Unterwurzacher | 2016-12-10 11:50:16 +0100 |
---|---|---|
committer | Jakob Unterwurzacher | 2016-12-10 11:54:36 +0100 |
commit | c9f4400e6dc71a36df5dc9725f52a8968f5f9803 (patch) | |
tree | 601cff97e2f5d472a68e3a133da43237af032521 /internal/contentenc/file_header.go | |
parent | 6c86afb5cd63b099d1762da1a2ce3f76703dc4fb (diff) |
Replace all calls to naked panic() with log.Panic()
We want all panics to show up in the syslog.
Diffstat (limited to 'internal/contentenc/file_header.go')
-rw-r--r-- | internal/contentenc/file_header.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/internal/contentenc/file_header.go b/internal/contentenc/file_header.go index 9ae5ae9..5c05818 100644 --- a/internal/contentenc/file_header.go +++ b/internal/contentenc/file_header.go @@ -7,6 +7,7 @@ package contentenc import ( "encoding/binary" "fmt" + "log" "github.com/rfjakob/gocryptfs/internal/cryptocore" ) @@ -30,7 +31,7 @@ type FileHeader struct { // Pack - serialize fileHeader object func (h *FileHeader) Pack() []byte { if len(h.ID) != headerIDLen || h.Version != CurrentVersion { - panic("FileHeader object not properly initialized") + log.Panic("FileHeader object not properly initialized") } buf := make([]byte, HeaderLen) binary.BigEndian.PutUint16(buf[0:headerVersionLen], h.Version) |