From: oharboe Date: Tue, 17 Feb 2009 11:54:30 +0000 (+0000) Subject: zy1000 1.49 snapshot X-Git-Tag: v0.2.0~1127 X-Git-Url: https://review.openocd.org/gitweb?p=openocd.git;a=commitdiff_plain;h=2136238908840dd230854cb5d78b8da181ca7340 zy1000 1.49 snapshot git-svn-id: svn://svn.berlios.de/openocd/trunk@1374 b42882b7-edfa-0310-969c-e2dbd0fdcd60 --- diff --git a/src/helper/startup.tcl b/src/helper/startup.tcl index 41137f1adb..eb965e009d 100644 --- a/src/helper/startup.tcl +++ b/src/helper/startup.tcl @@ -303,3 +303,11 @@ add_help_text srst_deasserted "Overridable procedure run when srst deassert is d proc srst_asserted {} { puts "Sensed nSRST asserted." } + +# catch any exceptions, capture output and return output +proc capture_catch {a} { + catch { + capture {uplevel $a} + } result + return $result +} diff --git a/src/server/httpd/httpd.tcl b/src/server/httpd/httpd.tcl index a2fee129d4..5b012681a6 100644 --- a/src/server/httpd/httpd.tcl +++ b/src/server/httpd/httpd.tcl @@ -99,14 +99,6 @@ proc encode {a} { return [string map {\n
{ } { } \t {        } > > < < / /} $a] } -# catch any exceptions, capture output and return it -proc capture_catch {a} { - catch { - capture {uplevel $a} - } result - return $result -} - proc first_flash_base {} { set t [lindex 0 [ocd_flash_banks]] return $t(base)