Giter Club home page Giter Club logo

zipstream's People

Contributors

krolaw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

zipstream's Issues

Getting empty file

Hi,

I came into a situation where I needed to read a zip file from an io.Reader and saw that you had the same issue and wrote this lib to solve it. I was able to use your library, however, when I try to use it with a helper function that I wrote (which just mocks a zip file in a bytes.Buffer) I am failing to read from the zip file.

Not sure whether you're maintaining this or not but here is the code reproducing my issue:
https://play.golang.org/p/nKUpO_nZQz

Thanks!

Panic reading zip

Hi,

Been getting a panic with a specific file.

panic: runtime error: slice bounds out of range

goroutine 1 [running]:
panic(0x105480, 0xc82000a0c0)
        /usr/local/go/src/runtime/panic.go:481 +0x3e6
github.com/krolaw/zipstream.(*descriptorReader).Read(0xc820012220, 0xc82007c000, 0x1000, 0x1000, 0x1000, 0x0, 0x0)
        /Users/orrikon/workspace/go/src/github.com/krolaw/zipstream/descriptor.go:49 +0x959

Can I email you the file?

usage with data descriptor record types

Trying to use this library to read a stream of zip files and am encounting an issue with zip files with a data descriptor record.

I have added logging into the example code for the Next method and it is discarding the entire file. I only receive the first file and the remaining content of the stream is discarded due to line 40 [1]

Does this library require the local header having compressed size and uncompressed size set?

It appears to have code for handling the data descriptor but even the unit tests discard the file contents and this results in a unusable library.

[1] https://github.com/krolaw/zipstream/blob/master/reader.go#L40

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.