Artifacts Associated With Ticket b6afa33737
Ticket change [810e8383ad] (rid 198339) by chrstphrchvz on 2022-02-19 13:49:20:
- assignee initialized to: "nobody"
- closer initialized to: "nobody"
- cmimetype initialized to: "text/x-fossil-wiki"
- comment initialized to:
Example script and corresponding output with UBSan error (<tt>-fsanitize=signed-integer-overflow</tt>, excludes any previously reported errors): <blockquote><pre> proc p {} { set a [string repeat [string repeat a 1023] 1049601] set a2 [string cat a $a $a] return [string toupper $a2] } set x [p] </pre> <pre> <span style="font-weight:bold">tcl/generic/tclExecute.c:5520:6:<span style="color:firebrick"> runtime error: </span>signed integer overflow: 2147483647 + 1 cannot be represented in type 'int'</span> </pre>(tclsh eventually exited normally)</blockquote> Can be prevented with same approach used in [a03e9793d4]; 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: "10. Objects"
- title initialized to:
signed integer overflow in TclInitStringRep() macro
- type initialized to: "Patch"
Add attachment "b6afa33737.diff" [751486b033] (rid 198340) by chrstphrchvz on 2022-02-19 13:49:38.
Ticket change [c4773d1c0f] (rid 198869) by jan.nijtmans on 2022-03-08 15:18:30:
- assignee changed to: "jan.nijtmans"
- closedate changed to: "2459647.1378531"
- closer changed to: "jan.nijtmans"
- comment changed to:
Example script and corresponding output with UBSan error (<tt>-fsanitize=signed-integer-overflow</tt>, excludes any previously reported errors): <blockquote><pre> proc p {} { set a [string repeat [string repeat a 1023] 1049601] set a2 [string cat a $a $a] return [string toupper $a2] } set x [p] </pre> <pre> <span style="font-weight:bold">tcl/generic/tclExecute.c:5520:6:<span style="color:firebrick"> runtime error: </span>signed integer overflow: 2147483647 + 1 cannot be represented in type 'int'</span> </pre>(tclsh eventually exited normally)</blockquote> Can be prevented with same approach used in [a03e9793d4]; see attached patch. - icomment: "Fixed [a314f4ea6233c15d|here]. Thanks!"
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"