Re: [go-nuts] Inevitable unexpected EOF

2016-11-27 Thread Connor Peet
That's exactly what I was look for, thanks so much! I've prefixed each message with its original size and it works perfectly. On Sunday, November 27, 2016 at 6:52:30 PM UTC-5, thebroke...@gmail.com wrote: > > This is entirely proper behavior of the gzip implementation (or more > specifically, c

Re: [go-nuts] Inevitable unexpected EOF

2016-11-27 Thread thebrokentoaster
This is entirely proper behavior of the gzip implementation (or more specifically, compress/flate). At the edges of the LZ77 window (approximately 32KiB), you are not guaranteed that you can simply for loop over the gzip.Reader until the input buffer is zero since the implementation of the deco

Re: [go-nuts] Inevitable unexpected EOF

2016-11-27 Thread Dan Kortschak
I don't see anywhere that you are closing the gzip.Writer. Does doing that fix the problem? On Fri, 2016-11-25 at 05:12 -0800, Connor wrote: > Hi all. > > I'm trying to implement a structure which gzips multipleĀ  > individually-inflatable messages in the same data stream. I've built > anĀ  > examp

[go-nuts] Inevitable unexpected EOF

2016-11-25 Thread Connor
Hi all. I'm trying to implement a structure which gzips multiple individually-inflatable messages in the same data stream. I've built an example implementation here: https://play.golang.org/p/hwdrVtI29t. While this works initially, eventually the gzip reader throws an "unexpected EOF" at me. I