summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsandeep <sandeep>2000-03-19 23:45:38 (GMT)
committersandeep <sandeep>2000-03-19 23:45:38 (GMT)
commit681c866be727a03776c6028f53bdae31049f770b (patch)
treeeb02f124ee8700d3575305b094b79b6634e36dfd
parent442e6551351a2b2547562fcb091d24518900f248 (diff)
downloadtcl-681c866be727a03776c6028f53bdae31049f770b.zip
tcl-681c866be727a03776c6028f53bdae31049f770b.tar.gz
tcl-681c866be727a03776c6028f53bdae31049f770b.tar.bz2
2000-03-19 Sandeep Tamhankar <sandeep@scriptics.com>scriptics_sc_2_0_b1
* library/http2.1/http.tcl: geturl used to throw an exception when the connection failed; I accidentally returned a token with the error info, breaking backwards compatibility. I changed it back to throwing an exception, but unsetting the state array first (thus still eliminating the original memory leak problem).
-rw-r--r--ChangeLog8
-rw-r--r--library/http/http.tcl15
-rw-r--r--library/http2.1/http.tcl15
-rw-r--r--library/http2.3/http.tcl15
4 files changed, 38 insertions, 15 deletions
diff --git a/ChangeLog b/ChangeLog
index 3924baa..7f0c2c5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
2000-03-19 Sandeep Tamhankar <sandeep@scriptics.com>
+ * library/http2.1/http.tcl: geturl used to throw an exception when
+ the connection failed; I accidentally returned a token with the
+ error info, breaking backwards compatibility. I changed it back
+ to throwing an exception, but unsetting the state array first
+ (thus still eliminating the original memory leak problem).
+
+2000-03-19 Sandeep Tamhankar <sandeep@scriptics.com>
+
* library/http2.1/http.tcl: Added -querychannel option and altered
some of Brent's modifications to allow asynchronous posts (via
-command). Also modified -queryprogress so that it calls the
diff --git a/library/http/http.tcl b/library/http/http.tcl
index b783dc7..a0e50d2 100644
--- a/library/http/http.tcl
+++ b/library/http/http.tcl
@@ -9,7 +9,7 @@
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: http.tcl,v 1.23 2000/03/19 22:32:26 sandeep Exp $
+# RCS: @(#) $Id: http.tcl,v 1.24 2000/03/19 23:45:38 sandeep Exp $
package provide http 2.3 ;# This uses Tcl namespaces
@@ -314,10 +314,15 @@ proc http::geturl { url args } {
set conStat [catch {eval $defcmd $async {$host $port}} s]
}
if {$conStat} {
- # something went wrong, so unset the state array and propagate the
- # error to the caller
- Finish $token $s
- return $token
+ # something went wrong while trying to establish the connection
+ # The proper response is probably to give the caller a token
+ # containing error info, but that would break backwards compatibility.
+ # So, let's follow tradition and throw an exception (after unsetting
+ # the array).
+ unset $token
+ error $s
+ #Finish $token $s
+ #return $token
}
set state(sock) $s
diff --git a/library/http2.1/http.tcl b/library/http2.1/http.tcl
index b783dc7..a0e50d2 100644
--- a/library/http2.1/http.tcl
+++ b/library/http2.1/http.tcl
@@ -9,7 +9,7 @@
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: http.tcl,v 1.23 2000/03/19 22:32:26 sandeep Exp $
+# RCS: @(#) $Id: http.tcl,v 1.24 2000/03/19 23:45:38 sandeep Exp $
package provide http 2.3 ;# This uses Tcl namespaces
@@ -314,10 +314,15 @@ proc http::geturl { url args } {
set conStat [catch {eval $defcmd $async {$host $port}} s]
}
if {$conStat} {
- # something went wrong, so unset the state array and propagate the
- # error to the caller
- Finish $token $s
- return $token
+ # something went wrong while trying to establish the connection
+ # The proper response is probably to give the caller a token
+ # containing error info, but that would break backwards compatibility.
+ # So, let's follow tradition and throw an exception (after unsetting
+ # the array).
+ unset $token
+ error $s
+ #Finish $token $s
+ #return $token
}
set state(sock) $s
diff --git a/library/http2.3/http.tcl b/library/http2.3/http.tcl
index b783dc7..a0e50d2 100644
--- a/library/http2.3/http.tcl
+++ b/library/http2.3/http.tcl
@@ -9,7 +9,7 @@
# See the file "license.terms" for information on usage and
# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: http.tcl,v 1.23 2000/03/19 22:32:26 sandeep Exp $
+# RCS: @(#) $Id: http.tcl,v 1.24 2000/03/19 23:45:38 sandeep Exp $
package provide http 2.3 ;# This uses Tcl namespaces
@@ -314,10 +314,15 @@ proc http::geturl { url args } {
set conStat [catch {eval $defcmd $async {$host $port}} s]
}
if {$conStat} {
- # something went wrong, so unset the state array and propagate the
- # error to the caller
- Finish $token $s
- return $token
+ # something went wrong while trying to establish the connection
+ # The proper response is probably to give the caller a token
+ # containing error info, but that would break backwards compatibility.
+ # So, let's follow tradition and throw an exception (after unsetting
+ # the array).
+ unset $token
+ error $s
+ #Finish $token $s
+ #return $token
}
set state(sock) $s