good morning!!!!

Skip to content
Snippets Groups Projects
Commit 482e06ea authored by alex.sharov's avatar alex.sharov
Browse files

uncompress: buf fix

parent 594477ab
No related branches found
No related tags found
No related merge requests found
......@@ -161,12 +161,13 @@ func doUncompress(cliCtx *cli.Context) error {
return err
}
if err := decompressor.WithReadAhead(func() error {
wr := bufio.NewWriterSize(os.Stdout, etl.BufIOSize)
wr := bufio.NewWriterSize(os.Stdout, 16*etl.BufIOSize)
defer wr.Flush()
g := decompressor.MakeGetter()
var buf []byte
buf := make([]byte, 0, 16*etl.BufIOSize)
var EOL = []byte("\n")
for g.HasNext() {
buf, _ := g.Next(buf[:0])
buf, _ = g.Next(buf[:0])
if _, err := wr.Write(buf); err != nil {
return err
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment