Commit 2851c510 authored by Han-Wen Nienhuys's avatar Han-Wen Nienhuys

zipfs: remove unused data type ZipFile

parent 6560fb0d
......@@ -6,10 +6,8 @@ package zipfs
import (
"archive/zip"
"bytes"
"context"
"fmt"
"io"
"io/ioutil"
"os"
"path/filepath"
......@@ -21,28 +19,6 @@ import (
"github.com/hanwen/go-fuse/nodefs"
)
type ZipFile struct {
*zip.File
}
func (f *ZipFile) Stat(out *fuse.Attr) {
}
func (f *ZipFile) Data() []byte {
zf := (*f)
rc, err := zf.Open()
if err != nil {
panic(err)
}
dest := bytes.NewBuffer(make([]byte, 0, f.UncompressedSize))
_, err = io.CopyN(dest, rc, int64(f.UncompressedSize))
if err != nil {
panic(err)
}
return dest.Bytes()
}
type zipRoot struct {
nodefs.Inode
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment