Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid left-shifting negative values to fix UBSAN warning
Instead, shift as an unsigned value, then convert back to signed: ``` ../3rdParty/jxrlib/image/decode/segdec.c:1081:36: runtime error: left shift of negative value -1 #0 0x7f0cc5c997c8 in DecodeMacroblockLowpass ../3rdParty/jxrlib/image/decode/segdec.c:1081 #1 0x7f0cc5c2f4f4 in processMacroblockDec ../3rdParty/jxrlib/image/decode/strdec.c:417 #2 0x7f0cc5c881f8 in ImageStrDecDecode ../3rdParty/jxrlib/image/decode/strdec.c:4010 #3 0x7f0cc5b82102 in PKImageDecode_Copy_WMP ../3rdParty/jxrlib/jxrgluelib/JXRGlueJxr.c:1874 ``` Co-authored-by: Milian Wolff <[email protected]>
- Loading branch information