Skip to content
Tcl Source Code Artifact [b183dfce90]
Login

Artifact [b183dfce90]

Artifact b183dfce903b032fced6d45c5250fe2f1b6d1592c690229554a1e00ab70ad4fb:

Ticket change [b183dfce90] - Ticket [21dbc600ae0a005a|21dbc600ae] <i>exec hangs, iff stdin &amp; stdout both were previously closed.</i> status still Open with 3 other changes by avl42 on 2022-12-06 11:56:25.
D 2022-12-06T11:56:25.310
J comment simplest\stest\sscript:\r\n\s\s\sclose\sstdin;\sclose\sstdout;\sexec\strue\r\n\r\nWorkaround\s(assuming\sthat\soriginal\sstdin\s&\s-out\sjust\sneed\sto\sbe\sclosed):\r\n\s\s\sclose\sstdin;\sclose\sstdout;\sopen\s/dev/null\sr;\sexec\strue\r\n\r\nIn\seither\scase:\sexec\sfirst\screates\sa\spipe,\sand\swhile\sthe\schild\sruns,\r\nthe\sparent\swaits\son\sthat\spipe\sfor\sEOF\s(probably\sinitiated\sfrom\sanother\sthread).\r\n\r\nWith\sat\sleast\sone\sof\sstdin\sor\sstdout\sNOT\sclosed\s(or\sre-opened\safterwards),\r\nthe\sEOF\son\sthat\spipe\sis\sseen,\sbut\swith\sBOTH\sstdin/-out\sclosed,\snothing\r\never\scloses\sthe\swrite-end\sof\sthe\spipe.\r\n\r\nPS:\sthat\spipe\sis\sNOT\sthe\sone\sby\swhich\sthe\smain\sprocess\scommunicates\sto\sthe\schild.
J login avl42
J mimetype text/plain
K 21dbc600ae0a005a7f879a05580550a8da257b14
U avl42
Z 2bc5e238072b6c8c4fac3a51bf4a6483