aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-02-21 23:21:32 +0800
committerGravatar Runxi Yu2026-02-21 23:21:32 +0800
commit6be32e9cf14a43cf6fb78a29943cb3b0e3d276b2 (patch)
treefd943a5decb8d5e43ed3630d259c749bb1c1ed5a
parentobjectstore/*, repository: Add ReadSize (diff)
signatureNo signature
internal/zlib: Use klauspost/compress/flate for now... v0.1.29
-rw-r--r--go.mod2
-rw-r--r--go.sum2
-rw-r--r--internal/zlib/reader.go3
-rw-r--r--internal/zlib/writer.go3
4 files changed, 8 insertions, 2 deletions
diff --git a/go.mod b/go.mod
index 2ea5559f..0fd9e922 100644
--- a/go.mod
+++ b/go.mod
@@ -1,3 +1,5 @@
module codeberg.org/lindenii/furgit
go 1.25.0
+
+require github.com/klauspost/compress v1.18.4
diff --git a/go.sum b/go.sum
new file mode 100644
index 00000000..1ef647c0
--- /dev/null
+++ b/go.sum
@@ -0,0 +1,2 @@
+github.com/klauspost/compress v1.18.4 h1:RPhnKRAQ4Fh8zU2FY/6ZFDwTVTxgJ/EMydqSTzE9a2c=
+github.com/klauspost/compress v1.18.4/go.mod h1:R0h/fSBs8DE4ENlcrlib3PsXS61voFxhIs2DeRhCvJ4=
diff --git a/internal/zlib/reader.go b/internal/zlib/reader.go
index 6e70fdea..60383ee1 100644
--- a/internal/zlib/reader.go
+++ b/internal/zlib/reader.go
@@ -35,13 +35,14 @@ package zlib
import (
"bufio"
- "compress/flate"
"encoding/binary"
"errors"
"hash"
"hash/adler32"
"io"
"sync"
+
+ "github.com/klauspost/compress/flate"
)
const (
diff --git a/internal/zlib/writer.go b/internal/zlib/writer.go
index 5497f089..608e35f2 100644
--- a/internal/zlib/writer.go
+++ b/internal/zlib/writer.go
@@ -5,13 +5,14 @@
package zlib
import (
- "compress/flate"
"encoding/binary"
"fmt"
"hash"
"hash/adler32"
"io"
"sync"
+
+ "github.com/klauspost/compress/flate"
)
// These constants are copied from the [flate] package, so that code that imports