.
D 2005-08-23T19:17:24
J assignee nijtmans
J cmimetype text/plain
J comment \n%\sset\sx\s[string\srepeat\sa\s65536];\sconcat\n%\sset\sy\s[lrepeat\s65536\s$x];\sconcat\n%\sstring\slength\s$y\nSegmentation\sfault\n\nThe\sstring\srep\sof\s$y\swould\sneed\na\sbuffer\sof\s4295032831\sbytes,\sbut\nthat\sexceeds\sINT_MAX.\n\nWhen\sthe\sscanner\s(over-)estimates\nthe\sbuffer\ssize,\sit\stries\sto\scount\sup\nthe\sneed\sfor\s4295163905\sbytes,\sbut\nthe\scalculation\soverflows,\swraps\saround\nand\sit\sconcludes\sthe\sneed\sfor\sonly\n196609\sbytes.\s\sThis\sgets\sallocated\seasily,\nand\swe\shappily\sstart\swriting\sto\sthis\nway\stoo\sshort\sbuffer\suntil\swe\smarch\soff\ninto\ssegfaulting\s.\n\nWould\sbe\sbetter\sfor\sthe\sscanner\sto\ndetect\sthe\soverflow\s(any\snegative\slength\nshould\sbe\sthe\sindicator)\sand\sTcl_Panic,\s\nI\sthink.
J foundin obsolete:\s8.5a4
J priority 9\sImmediate
J resolution None
J status Open
J submitter dgp
J subsystem 14.\sList\sObject
J title UpdateStringOfList:\soverflow\sdetection
J type Bug
K 1267380fffffffffffffffffffffffffffffffff
U dgp
Z e8a9325da58c7eab46d5f623adfe561e