-
Notifications
You must be signed in to change notification settings - Fork 12
Closed
Description
Specifically, pierrec/lz4#229 (implementing frame concatenation) breaks this piece of code:
Lines 275 to 281 in 133c1b1
| // readLZ4Trailer reads the LZ4 trailer frame to ensure we hit EOF. | |
| func (dec *Decoder) readLZ4Trailer() error { | |
| if _, err := io.ReadFull(dec.zr, make([]byte, 1)); err != io.EOF { | |
| return fmt.Errorf("expected lz4 end frame") | |
| } | |
| return nil | |
| } |
readLZ4Trailer wants pierrec/lz4 to consume the trailer - and verify the checksum - but in doing so, it peeks into the subsequent data, finds an invalid signature, and errors out.
Even if you ignore that error, your stream is now in an invalid state to continue reading the next page.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels