Skip to content

Commit

Permalink
Switch zip handling to use github.com/klauspost/compress/zip (#273)
Browse files Browse the repository at this point in the history
* Switch zip handling to use github.com/klauspost/compress/zip

This improves the performence over teh stdlib implementation.

* Add in a couple missed changes
  • Loading branch information
Jacalz committed Dec 23, 2020
1 parent 5e44732 commit 699ca56
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cmd/arc/main.go
Expand Up @@ -2,7 +2,6 @@ package main

import (
"archive/tar"
"archive/zip"
"bytes"
"compress/flate"
"flag"
Expand All @@ -11,6 +10,7 @@ import (
"path/filepath"
"strings"

"github.com/klauspost/compress/zip"
"github.com/mholt/archiver/v3"
"github.com/nwaples/rardecode"
)
Expand Down
3 changes: 2 additions & 1 deletion testdata/create-evil-zip.go
@@ -1,10 +1,11 @@
package main

import (
"archive/zip"
"log"
"os"
"time"

"github.com/klauspost/compress/zip"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion zip.go
@@ -1,7 +1,6 @@
package archiver

import (
"archive/zip"
"bytes"
"compress/flate"
"fmt"
Expand All @@ -14,6 +13,7 @@ import (
"strings"

"github.com/dsnet/compress/bzip2"
"github.com/klauspost/compress/zip"
"github.com/klauspost/compress/zstd"
"github.com/ulikunitz/xz"
)
Expand Down

0 comments on commit 699ca56

Please sign in to comment.