aboutsummaryrefslogtreecommitdiff
path: root/regtest.tcl
diff options
context:
space:
mode:
authorSteve Bennett <steveb@workware.net.au>2017-05-12 11:53:01 +1000
committerSteve Bennett <steveb@workware.net.au>2017-05-12 13:02:15 +1000
commitc8e41c8a8a0d6cae87f89a6b26b336b2df8099d2 (patch)
tree7b67cf2effc2846b1409d2c76b2e0d1721966768 /regtest.tcl
parent002a3ef0b663724b0f43dbd2d184505afae6dd3e (diff)
downloadjimtcl-c8e41c8a8a0d6cae87f89a6b26b336b2df8099d2.zip
jimtcl-c8e41c8a8a0d6cae87f89a6b26b336b2df8099d2.tar.gz
jimtcl-c8e41c8a8a0d6cae87f89a6b26b336b2df8099d2.tar.bz2
lsort -unique: Fix case with no duplicates
In this case the final element was written a second time. Reported-by: Ryan Whitworth <me@ryanwhitworth.com> Signed-off-by: Steve Bennett <steveb@workware.net.au>
Diffstat (limited to 'regtest.tcl')
-rw-r--r--regtest.tcl5
1 files changed, 5 insertions, 0 deletions
diff --git a/regtest.tcl b/regtest.tcl
index 0761c49..df25d13 100644
--- a/regtest.tcl
+++ b/regtest.tcl
@@ -310,6 +310,11 @@ puts "TEST 42 PASSED"
catch {format %----------------------------------------d 1}
puts "TEST 43 PASSED"
+# REGTEST 44
+# lsort -unique with no duplicate - invalid memory write
+lsort -unique {a b c d}
+puts "TEST 44 PASSED"
+
# TAKE THE FOLLOWING puts AS LAST LINE
puts "--- ALL TESTS PASSED ---"