Page MenuHomeFreeBSD

uncompress: Avoid reading an extra byte
ClosedPublic

Authored by imp on Oct 10 2024, 5:02 PM.
Tags
None
Referenced Files
Unknown Object (File)
Jan 29 2025, 6:53 AM
Unknown Object (File)
Jan 22 2025, 6:19 PM
Unknown Object (File)
Jan 17 2025, 4:20 PM
Unknown Object (File)
Jan 15 2025, 7:03 PM
Unknown Object (File)
Jan 15 2025, 7:01 PM
Unknown Object (File)
Jan 15 2025, 3:58 PM
Unknown Object (File)
Dec 28 2024, 10:07 AM
Unknown Object (File)
Nov 24 2024, 4:33 PM
Subscribers
None

Details

Summary

When reading the next code in a stream, avoid reading an extra byte if
we're going to throw it away. When there's no more bits to extract from
the stream, bits will be 0 and we'll mask the read byte with 0 anyway.
At worst, this will avoid reading one past the end of gbuf array (which
is not possible in well formed streams).

PR: 127912

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable