You are viewing a plain text version of this content. The canonical link for it is here.
Posted to site-cvs@tcl.apache.org by mx...@apache.org on 2016/11/15 16:43:16 UTC
svn commit: r1769855 - in /tcl/rivet/branches/2.3: ChangeLog
rivet/rivet-tcl/catch.tcl rivet/rivet-tcl/try.tcl
Author: mxmanghi
Date: Tue Nov 15 16:43:16 2016
New Revision: 1769855
URL: http://svn.apache.org/viewvc?rev=1769855&view=rev
Log:
* rivet/rivet-tcl/catch.tcl|try.tcl: better
script evaluation is catch/try construct,
specified complete ::rivet::abort_page generated
error codes
Modified:
tcl/rivet/branches/2.3/ChangeLog
tcl/rivet/branches/2.3/rivet/rivet-tcl/catch.tcl
tcl/rivet/branches/2.3/rivet/rivet-tcl/try.tcl
Modified: tcl/rivet/branches/2.3/ChangeLog
URL: http://svn.apache.org/viewvc/tcl/rivet/branches/2.3/ChangeLog?rev=1769855&r1=1769854&r2=1769855&view=diff
==============================================================================
--- tcl/rivet/branches/2.3/ChangeLog (original)
+++ tcl/rivet/branches/2.3/ChangeLog Tue Nov 15 16:43:16 2016
@@ -1,3 +1,9 @@
+2016-11-15 Massimo Manghi <mx...@apache.org>
+ * rivet/rivet-tcl/catch.tcl|try.tcl: better
+ script evaluation is catch/try construct,
+ specified complete ::rivet::abort_page generated
+ error codes
+
2016-11-09 Massimo Manghi <mx...@apache.org>
* src/mod_rivet/mod_rivet_common.c: the request_rec
field to be checked in order to determine whether we
Modified: tcl/rivet/branches/2.3/rivet/rivet-tcl/catch.tcl
URL: http://svn.apache.org/viewvc/tcl/rivet/branches/2.3/rivet/rivet-tcl/catch.tcl?rev=1769855&r1=1769854&r2=1769855&view=diff
==============================================================================
--- tcl/rivet/branches/2.3/rivet/rivet-tcl/catch.tcl (original)
+++ tcl/rivet/branches/2.3/rivet/rivet-tcl/catch.tcl Tue Nov 15 16:43:16 2016
@@ -1,26 +1,26 @@
# -- catch.tcl
#
-# Wrapper of the core [::catch] command that checks whether
+# Wrapper of the core [catch] command that checks whether
# an error condition is actually raised by [::rivet::abort_page]
# or [::rivet::exit]. In case the error is thrown again to allow
# the interpreter to interrupt and pass execution to AbortScript
#
-# $Id $
+# $Id$
#
namespace eval ::rivet {
proc catch {script args} {
- set catch_ret [uplevel [list ::catch $script] $args]
+ set catch_ret [uplevel [list ::catch $script {*}$args]]
if {$catch_ret && [::rivet::abort_page -aborting]} {
- return -code error -errorcode ABORTPAGE
+ return -code error -errorcode {RIVET ABORTPAGE} "Page abort"
} elseif {$catch_ret && [::rivet::abort_page -exiting]} {
- return -code error -errorcode EXITPAGE
+ return -code error -errorcode {RIVET THREAD_EXIT} "Thread exit"
} else {
Modified: tcl/rivet/branches/2.3/rivet/rivet-tcl/try.tcl
URL: http://svn.apache.org/viewvc/tcl/rivet/branches/2.3/rivet/rivet-tcl/try.tcl?rev=1769855&r1=1769854&r2=1769855&view=diff
==============================================================================
--- tcl/rivet/branches/2.3/rivet/rivet-tcl/try.tcl (original)
+++ tcl/rivet/branches/2.3/rivet/rivet-tcl/try.tcl Tue Nov 15 16:43:16 2016
@@ -2,7 +2,7 @@
#
# Wrapper of the core [try] command
#
-# $Id $
+# $Id$
#
namespace eval ::rivet {
@@ -10,11 +10,11 @@ namespace eval ::rivet {
proc try {script args} {
uplevel [list ::try $script trap {RIVET ABORTPAGE} {} {
- return -errorcode ABORTPAGE -code error
- } trap {RIVET EXITPAGE} {} {
- return -errorcode EXITPAGE -code error
- } {*}$args]
+ return -errorcode {RIVET ABORTPAGE} -code error
+ } trap {RIVET THREAD_EXIT} {} {
+ return -errorcode {RIVET THREAD_EXIT} -code error
+ } {*}$args]
}
-}
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: site-cvs-unsubscribe@tcl.apache.org
For additional commands, e-mail: site-cvs-help@tcl.apache.org