diff options
author | sebres <sebres@users.sourceforge.net> | 2024-03-07 11:21:03 (GMT) |
---|---|---|
committer | sebres <sebres@users.sourceforge.net> | 2024-03-07 11:21:03 (GMT) |
commit | e994a261ab569cd852c7e5d432efb9eeb7a12089 (patch) | |
tree | 1f19ef2b4d2a2d9a80e781833224ff1450d66217 /tests | |
parent | 03f7d8bcf14b819439604e888920a55c697fb6c1 (diff) | |
download | tcl-e994a261ab569cd852c7e5d432efb9eeb7a12089.zip tcl-e994a261ab569cd852c7e5d432efb9eeb7a12089.tar.gz tcl-e994a261ab569cd852c7e5d432efb9eeb7a12089.tar.bz2 |
fixes segfault [a9625d1f53554f9d]: elemObj used uninitialized, lindex on lseq wo args must return whole list
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lseq.test | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/lseq.test b/tests/lseq.test index 2a7de67..c2264da 100644 --- a/tests/lseq.test +++ b/tests/lseq.test @@ -674,6 +674,13 @@ test lseq-4.19 {varnames} -body { unset {*}$varlist res varlist v plist } -result {auto_execok 1 auto_load 2 auto_qualify 2 arithseries} +test lseq-4.20 {lindex on lseq without index args, bug a9625d1f53554f9d} -body { + set res [lindex [lseq 1000]] + list [llength $res] [lindex $res 0] [lindex $res end] +} -cleanup { + unset -nocomplain res +} -result {1000 0 999} + test lseq-convertToList {does not result in a memory error} -body { trace add variable var1 write [list ::apply [list args { error {this is an error} |