Overview
| Artifact ID: | 60e2f44bfc1473ea9fc96bbc4864156c3006efa2 |
|---|---|
| Ticket: | 218998ffffffffffffffffffffffffffffffffff
Insufficient error handling generates exception |
| User & Date: | nobody on 2000-10-26 01:09:07 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
OriginalBugID: 3752 Bug Version: 8.2.2 SubmitDate: '1999-12-02' LastModified: '1999-12-03' Severity: CRIT Status: Released Submitter: techsupp ChangedBy: hobbs OS: Solaris Machine: Sun Ultra Sparc FixedDate: '1999-12-03' FixedInVersion: 8.2.3 ClosedDate: '2000-10-25' Name: Q. Alex Zhao Comments: If "catch" catches an error, n is undefined, causing "if {$n == 0} ..." to fail. Use "elseif" should fix the problem. ReproducibleScript: Use the http package to fetch a Web page. ObservedBehavior: can't read "n": no such variable while executing "if {$n == 0} { set state(state) body if {![regexp -nocase ^text $state(type)]} { # Turn off conversions for non-text data fconfigure $s ..." (procedure "http::Event" line 14) invoked from within "http::Event ::http::722" DesiredBehavior: no error Patch: *** http.tcl.old Fri Nov 19 18:10:08 1999 --- http.tcl Thu Dec 2 13:13:30 1999 *************** *** 449,456 **** if {[string equal $state(state) "header"]} { if {[catch {gets $s line} n]} { Finish $token $err ! } ! if {$n == 0} { set state(state) body if {![regexp -nocase ^text $state(type)]} { # Turn off conversions for non-text data --- 449,455 ---- if {[string equal $state(state) "header"]} { if {[catch {gets $s line} n]} { Finish $token $err ! } elseif {$n == 0} { set state(state) body if {![regexp -nocase ^text $state(type)]} { # Turn off conversions for non-text data PatchFiles: http.tcl Good fix, wrong problem (user was using 8.1.1 actually). The necessary fixes have been applied for 8.2.3/8.3. -- 12/03/1999 hobbs - foundin changed to: "obsolete: 8.2.2"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "nobody"
- subsystem changed to: "69. Other"
- title changed to: "Insufficient error handling generates exception"
- type changed to: "Bug"