Skip to content

Commit

Permalink
[vm/io] Explain why the return of inflateReset can be ignored
Browse files Browse the repository at this point in the history
Change-Id: I9e2bda9786f15118b422db2d6dc9c2b4aee3e272
Tested: comment-only
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/369180
Reviewed-by: Alexander Aprelev <[email protected]>
Commit-Queue: Brian Quinlan <[email protected]>
  • Loading branch information
brianquinlan authored and Commit Queue committed May 31, 2024
1 parent 28be4ef commit 51ea22f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions runtime/bin/filter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,10 @@ intptr_t ZLibInflateFilter::Processed(uint8_t* buffer,
// ...gzip.encode([4, 5, 6]),
// ];
// final decoded = gzip.decode(data); // [1, 2, 3, 4, 5, 6]

// The return code for `inflateReset` can be ignored because, if the
// result is an error, the same error will be returned in the next
// call to `inflate`.
inflateReset(&stream_);
}
if (processed == 0) {
Expand Down

0 comments on commit 51ea22f

Please sign in to comment.