diff options
author | sebres <sebres@users.sourceforge.net> | 2017-11-29 13:59:42 (GMT) |
---|---|---|
committer | sebres <sebres@users.sourceforge.net> | 2017-11-29 13:59:42 (GMT) |
commit | e68b4918069d622ccc7f9f6f98e8432df3f3baad (patch) | |
tree | 4aef3d9f87b3229d1ee44a421955d6680bf47632 /tests | |
parent | ff436137df3cce5d4e96e59c54a3f1211a3e8a33 (diff) | |
download | tcl-e68b4918069d622ccc7f9f6f98e8432df3f3baad.zip tcl-e68b4918069d622ccc7f9f6f98e8432df3f3baad.tar.gz tcl-e68b4918069d622ccc7f9f6f98e8432df3f3baad.tar.bz2 |
Cherry-picked test-cases from [046a5af026]: fix for issue [4f6a1ebd64]: ensemble: segmentation fault when -subcommand and
-map values are the same object.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/namespace.test | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/namespace.test b/tests/namespace.test index 71b6860..7d41258 100644 --- a/tests/namespace.test +++ b/tests/namespace.test @@ -1576,7 +1576,10 @@ test namespace-42.7 {ensembles: nested} { namespace delete ns set result } {{1 ::ns::x0::z} 1 2 3} -test namespace-42.8 {ensembles: [Bug 1670091]} -setup { +test namespace-42.8 { + ensembles: [Bug 1670091], panic due to pointer to a deallocated List + struct. +} -setup { proc demo args {} variable target [list [namespace which demo] x] proc trial args {variable target; string length $target} @@ -1591,6 +1594,19 @@ test namespace-42.8 {ensembles: [Bug 1670091]} -setup { rename foo {} } -result {} +test namespace-42.9 { + ensembles: [Bug 4f6a1ebd64], segmentation fault due to pointer to a + deallocated List struct. +} -setup { + namespace eval n {namespace ensemble create} + dict set list one ::two + namespace ensemble configure n -subcommands $list -map $list +} -body { + n one +} -cleanup { + namespace delete n +} -returnCodes error -match glob -result {invalid command name*} + test namespace-43.1 {ensembles: dict-driven} { namespace eval ns { namespace export x* |