Closed mgorny closed 4 months ago
Thanks @mgorny, not only for the PR, but also for reporting the issue and doing the root-cause analysis. Changes look fine to me, I agree the cast was completely unnecessary. I'll tag a release shortly.
@mgorny 2.4.1 has been tagged, a new release will hopefully appear automatically in PyPI in an hour or less; otherwise tomorrow I'll have a look.
Thanks!
Fix
_crc32c_sw_slicing_by_8()
to useunsigned char
forp_buf
, to fix incorrect results on platforms with signedchar
such as SPARC. The code has been castingunsigned char *
tochar *
for no apparent reason, and this broke the bitshifts in the big endian blocks.Particularly,
would be XOR-ed against
0xffee0000
rather than0x00ee0000
.Fixes #43