Artifacts Associated With Ticket d282fcacd1
Ticket change [8543f7b807] (rid 198199) by chrstphrchvz on 2022-02-17 06:17:58:
- assignee initialized to: "nobody"
- closer initialized to: "nobody"
- cmimetype initialized to: "text/x-fossil-wiki"
- comment initialized to:
UBSan (<tt>-fsanitize=shift-base</tt>) errors for 32-bit <tt>long</tt>: <blockquote><pre> % binary scan \x00\x00\x00\x80 i myvar <span style="font-weight:bold">tcl/generic/tclBinary.c:2105:28:<span style="color:red"> runtime error: </span>left shift of 128 by 24 places cannot be represented in type 'long int'</span> 1 % binary scan \x80\x00\x00\x00 I myvar <span style="font-weight:bold">tcl/generic/tclBinary.c:2110:29:<span style="color:red"> runtime error: </span>left shift of 128 by 24 places cannot be represented in type 'long int'</span> 1 </pre></blockquote> This can be avoided by casting at least the most significant source byte to <tt>unsigned long</tt> before shifting; see attached patch.
- foundin initialized to: "core-8-6-branch"
- is_private initialized to: "0"
- login: "chrstphrchvz"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- severity initialized to: "Minor"
- status initialized to: "Open"
- submitter initialized to: "chrstphrchvz"
- subsystem initialized to: "16. Commands A-H"
- title initialized to: "signed integer overflow in ScanNumber()"
- type initialized to: "Patch"
Add attachment "scannumber.diff" [8dafa9ce36] (rid 198200) by chrstphrchvz on 2022-02-17 06:18:13.
Ticket change [cb72eff41e] (rid 198434) by jan.nijtmans on 2022-02-23 15:49:34:
- assignee changed to: "jan.nijtmans"
- closedate changed to: "2459634.15942809"
- closer changed to: "jan.nijtmans"
- icomment:
Fixed [d7a73dbf01aedfc5|here] Thanks for the report and the patch!
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"