Skip to content
Tcl Source Code Artifact [0213a1da76]
Login

Artifact [0213a1da76]

Artifact 0213a1da7668ca01de3508d8002111066c85ae75:

Ticket change [0213a1da76] - Ticket [8bd13f07bde6fb06|8bd13f07bd] <i>Closing tcl pipes prevents windows threads from starting up</i> status still Pending with 3 other changes by sebres on 2017-05-03 10:40:46.
D 2017-05-03T10:40:46.925
J icomment Back-ported\sto\score-8-5-branch\s(see\s[core-8-5-branch-fix-1997007]).\r\nTest\scases\sfixed\sand\snormalized\ssimilar\s8.6-version.\r\n\r\nBTW\sBy\stesting\sI\sfound\sanother\svery\ssporadic\sbug\s(present\sin\sall\sversions),\sand\sfixed\snow\sin\sthis\s8.5th\sbranch\s(I'll\spartially\smerge\sit\sto\s8.6/trunk\slater):\r\n\r\n\s\s"Runtime\sError\sR6016\s-\sNot\senough\sspace\sfor\sthread\sdata"\r\n\r\nBug\sgoes\sto\susage\sof\sCreateThread\s(together\swith\sCRT/TLS,\sthat\smay\scause\sconflict\sby\sloading\sDLL,\sresp.\sattach\sthread\sto\sthe\sDLL).\r\n\r\nSee\ssection\s"Remarks"\sin\shttps://msdn.microsoft.com/en-us/library/windows/desktop/ms682453(v=vs.85).aspx\r\n\r\nSo\sintroduces\snew\sthreaded\sdeclarations\sTclWinThreadCreate/TclWinThreadExit:\r\nbecause\sof\susage\sof\sCRT\sand/or\sTLS\s(if\sthreaded)\s-\suse\sthe\s_beginthreadex/_endthreadex\sfunctions\sfor\sthread\smanagement\srather\sthan\sCreateThread/ExitThread.\r\nPrevents\ssporadic\srun-time\serrors,\slike\sR6016\s(not\senough\sspace\sfor\sthread\sdata).\r\n\r\nIt\sis\sextremely\ssporadic\sand\shard\sto\sreproduce\s(expected\snested\sexec\sof\ssomething\susing\stcl.dll\sand\svery\sfast\smulti-core\sCPU),\se.\sg.\sit\sis\sreproduceable\sby\srepeated\scalls\sof\sthe\s"exec.test".\r\nFor\sexample:\r\n\r\n%\stime\s{\sputs\s[exec\stclsh85t.exe\s../../tests/all.tcl\s-file\s*exec.*]\s}\s50\r\n\r\n====\sexec-6.2\sredirecting\sstderr\sthrough\sa\spipeline\sFAILED\r\n====\sContents\sof\stest\scase:\r\n\r\n\s\s\s\sexec\s[interpreter]\s"$path(sh)"\s-c\s"\\"$path(echo)\\"\sfoo\sbar\s1>&2"\s|&\s[interpreter]\s"$path(cat)"\r\n\r\n----\sResult\swas:\r\nfoo\sbar\r\n\r\nruntime\serror\sR6016\r\n-\snot\senough\sspace\sfor\sthread\sdata\r\n----\sResult\sshould\shave\sbeen\s(exact\smatching):\r\nfoo\sbar\r\n====\sexec-6.2\sFAILED\r\n\r\nFixed\sin\s[44defcb5cfc826569797f0bbe474595dbc454c01]
J login sebres
J mimetype text/plain
K 8bd13f07bde6fb0631f27927e36461fdefe8ca95
U sebres
Z 5d8f85c41bb07648d646e1bb511c9699