summaryrefslogtreecommitdiff
path: root/vendor/github.com/ulikunitz/xz/writer.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/ulikunitz/xz/writer.go')
-rw-r--r--vendor/github.com/ulikunitz/xz/writer.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/vendor/github.com/ulikunitz/xz/writer.go b/vendor/github.com/ulikunitz/xz/writer.go
index aec10dfa6..a9ed44912 100644
--- a/vendor/github.com/ulikunitz/xz/writer.go
+++ b/vendor/github.com/ulikunitz/xz/writer.go
@@ -6,6 +6,7 @@ package xz
import (
"errors"
+ "fmt"
"hash"
"io"
@@ -190,6 +191,9 @@ func (c WriterConfig) NewWriter(xz io.Writer) (w *Writer, err error) {
return nil, err
}
data, err := w.h.MarshalBinary()
+ if err != nil {
+ return nil, fmt.Errorf("w.h.MarshalBinary(): error %w", err)
+ }
if _, err = xz.Write(data); err != nil {
return nil, err
}