summaryrefslogtreecommitdiffstats
path: root/tests/ioCmd.test
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2014-04-15 16:09:28 (GMT)
committerdgp <dgp@users.sourceforge.net>2014-04-15 16:09:28 (GMT)
commitd25403a5a8b4f784566eb15f30b46ed568efc478 (patch)
tree45b647e651408983ccc93c3ec3b23ca9476fdaf4 /tests/ioCmd.test
parentc5510a29171fa3a62f7a51af11bea2772bf10e3e (diff)
downloadtcl-d25403a5a8b4f784566eb15f30b46ed568efc478.zip
tcl-d25403a5a8b4f784566eb15f30b46ed568efc478.tar.gz
tcl-d25403a5a8b4f784566eb15f30b46ed568efc478.tar.bz2
[88aef05cda] Stop reentrancy segfault in reflected channels by managing
callbacks as (copies of) lists, not shared Tcl_Obj arrays. Still could use cleanup and improvements.
Diffstat (limited to 'tests/ioCmd.test')
-rw-r--r--tests/ioCmd.test19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/ioCmd.test b/tests/ioCmd.test
index bdf0fb3..f021ade 100644
--- a/tests/ioCmd.test
+++ b/tests/ioCmd.test
@@ -755,6 +755,25 @@ test iocmd-21.19 {chan create, init failure -> no channel, no finalize} -match g
rename foo {}
set res
} -result {{} {initialize rc* {read write}} 1 {*all required methods*} {}}
+test iocmd-21.20 {Bug 88aef05cda} -setup {
+ proc foo {method chan args} {
+ switch -- $method blocking {
+ chan configure $chan -blocking [lindex $args 0]
+ return
+ } initialize {
+ return {initialize finalize watch blocking read write
+ configure cget cgetall}
+ } finalize {
+ return
+ }
+ }
+ set ch [chan create {read write} foo]
+} -body {
+ list [catch {chan configure $ch -blocking 0} m] $m
+} -cleanup {
+ close $ch
+ rename foo {}
+} -match glob -result {1 {*nested eval*}}
# --- --- --- --------- --------- ---------
# Helper commands to record the arguments to handler methods.