From 34d169db115f8e1476aa5fa4bf9c41d5f04195b1 Mon Sep 17 00:00:00 2001 From: msofer Date: Mon, 19 Nov 2001 21:04:41 +0000 Subject: * tests/compile.test: added a test for bug [Bug 483309] FossilOrigin-Name: 34e03422d051c9d80c594cc78a20dbbc51236c98 --- ChangeLog | 4 ++++ tests/compile.test | 15 ++++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index f6abdd0..ace0c3c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2001-11-19 Miguel Sofer + + * tests/compile.test: added a test for bug [Bug 483309] + 2001-11-19 Vince Darley * win/tclWinFile.c: diff --git a/tests/compile.test b/tests/compile.test index dfa5770..abadee0 100644 --- a/tests/compile.test +++ b/tests/compile.test @@ -11,7 +11,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: compile.test,v 1.13 2001/10/12 21:04:15 msofer Exp $ +# RCS: @(#) $Id: compile.test,v 1.14 2001/11/19 21:04:42 msofer Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -286,6 +286,19 @@ test compile-12.2 {testing error on literal deletion} {memDebug execCommandExist set res } 0 +# Special test for underestimating the maxStackSize required for a +# compiled command. A failure will cause a segfault in the child +# process. +test compile-13.1 {testing underestimate of maxStackSize in list cmd} { + set body {set x [list} + for {set i 0} {$i < 3000} {incr i} { + append body " $i" + } + append body {]; puts OK} + regsub BODY {proc crash {} {BODY}; crash} $body script + list [catch {exec [info nameofexecutable] << $script} msg] $msg +} {0 OK} + # cleanup catch {rename p ""} catch {namespace delete test_ns_compile} -- cgit v0.12