| ... | @@ -421,14 +421,14 @@ pub fn decodeZstandardFrameBlocksArrayList( | ... | @@ -421,14 +421,14 @@ pub fn decodeZstandardFrameBlocksArrayList( |
| 421 | hasher.update(written_slice.second); | 421 | hasher.update(written_slice.second); |
| 422 | } | 422 | } |
| 423 | } | 423 | } |
| 424 | const added_len = dest.items.len - initial_len; | | |
| 425 | if (frame_context.content_size) |size| { | | |
| 426 | if (added_len != size) { | | |
| 427 | return error.BadContentSize; | | |
| 428 | } | | |
| 429 | } | | |
| 430 | if (block_header.last_block) break; | 424 | if (block_header.last_block) break; |
| 431 | } | 425 | } |
| | 426 | const added_len = dest.items.len - initial_len; |
| | 427 | if (frame_context.content_size) |size| { |
| | 428 | if (added_len != size) { |
| | 429 | return error.BadContentSize; |
| | 430 | } |
| | 431 | } |
| 432 | | 432 | |
| 433 | if (frame_context.has_checksum) { | 433 | if (frame_context.has_checksum) { |
| 434 | if (src.len < consumed_count + 4) return error.EndOfStream; | 434 | if (src.len < consumed_count + 4) return error.EndOfStream; |