.
D 2007-12-05T20:30:37
J assignee andreas_kupries
J cmimetype text/plain
J comment Using\stcl8.4.14\son\sUbuntu\s7.10\s(Linux\skernel\s2.6.22)\n\nIn\sinteractive\smode,\sthe\sTCL\sshell\sblocks\sin\sa\sread()\ssystem\scall\swaiting\sfor\sa\scommand\sto\sbe\styped.\s\sIf\sa\ssignal\sis\sreceived,\sthe\sread()\scall\sreturns\sEINTR\s(see\snote\s1)\sto\sindicate\sthat\sthe\ssystem\scall\swas\sinterrupted.\n\nThe\scode\sin\sFilterInputBytes\sdoes\snot\stest\sfor\sthe\sEINTR\serror\scode\s--\sit\streats\sit\slike\sa\shard\serror\seven\sthough\sother\sroutines\sin\sthe\ssame\sfile\swhich\suse\sGetInput\sdo\shandle\sthe\sEINTR\scase.\n\nThis\smakes\sit\simpossible\sto\suse\sa\ssignal\shandler\swith\san\sinteractive\sTCL\sapplication.\s\sEven\sif\sthe\ssignal\sis\scaught\sand\shandled\scorrectly\sby\sthe\sapplication,\sthe\sinterrupted\sread()\ssyscall\swill\sreturn\sEINTR\sand\sthis\swill\sbe\streated\slike\sa\shard\serror,\sdumping\sme\sout\sof\sthe\sinterpreter\swithout\sa\schance\sto\srestart\sthe\sread()\scall.\n\nThe\sbehavior\sI\sexpect\sis\sthat\sTCL\sshould\sdetect\sthe\sEINTR\serror\scode\sand\srestart\sthe\sinterrupted\sread().\n\nIn\smy\scase,\sI\sam\sinstalling\sa\shandler\sfor\sSIGINT,\sso\sthat\sI\scan\scatch\sand\smake\suse\sof\sa\sCtrl-C\sfrom\sthe\skeyboard\sto\ssafely\sabort\sa\slong-running\scommand.\s\sUnfortunately,\sit\scurrently\shas\sthe\seffect\sof\saborting\sthe\sentire\sTCL\ssession\sas\swell,\sdue\sto\sthis\sbug.\n\nThanks,\nJeff\sNewbern\[email protected]\n\nNote\s1:\sActually\son\smy\ssystem\sit\sreturns\sERESTARTSYS\sdue\sto\sa\skernel\sbug,\sbut\sthis\sis\sa\sseparate\sissue\sfrom\sthe\sTCL\sbug,\swhich\sremains\seven\safter\sthe\skernel\sis\sfixed.
J foundin None
J is_private 0
J priority 5\sMedium
J resolution None
J status Open
J submitter jnewbern
J subsystem 25.\sChannel\sSystem
J title FilterInputBytes/GetInput\sdo\snot\shandle\sEINTR
J type Bug
K 1845108fffffffffffffffffffffffffffffffff
U jnewbern
Z 5c323e80938eecb87cdcd16e99648e33