summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2002-12-11 21:29:52 (GMT)
committerdgp <dgp@users.sourceforge.net>2002-12-11 21:29:52 (GMT)
commit7c29f89d1b5523989d28042e893c40042981a83c (patch)
treef1df1b1af2f72af74a1be0b28fb037d64f34e97f /tests
parent0ebb8899a331886beaa24f4ff1ab19b68fd590d9 (diff)
downloadtcl-7c29f89d1b5523989d28042e893c40042981a83c.zip
tcl-7c29f89d1b5523989d28042e893c40042981a83c.tar.gz
tcl-7c29f89d1b5523989d28042e893c40042981a83c.tar.bz2
* generic/tclProc.c (ProcessProcResultCode): Fix failure to
propagate negative return codes up the call stack. [Bug 647307] * tests/proc.test (proc-6.1): Test for Bug 647307
Diffstat (limited to 'tests')
-rw-r--r--tests/proc.test11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/proc.test b/tests/proc.test
index a982d78..ce07e88 100644
--- a/tests/proc.test
+++ b/tests/proc.test
@@ -13,7 +13,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: proc.test,v 1.10 2001/09/10 17:04:10 msofer Exp $
+# RCS: @(#) $Id: proc.test,v 1.11 2002/12/11 21:29:52 dgp Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -316,6 +316,15 @@ test proc-5.1 {Bytecompiling noop; test for correct argument substitution} {
set result
} {aba}
+test proc-6.1 {ProcessProcResultCode: Bug 647307 (negative return code)} {
+ proc a {} {return -code -5}
+ proc b {} a
+ set result [catch b]
+ rename a {}
+ rename b {}
+ set result
+} -5
+
# cleanup
catch {rename p ""}
catch {rename t ""}