Tcl Source Code

View Ticket
Login
Ticket UUID: 451200
Title: Test ioUtil-3.7 relies on bug
Type: Bug Version: obsolete: 8.4a4
Submitter: msofer Created on: 2001-08-15 15:14:53
Subsystem: 37. File System Assigned To: dgp
Priority: 5 Medium Severity:
Status: Closed Last Modified: 2001-08-22 22:48:10
Resolution: Fixed Closed By: dgp
    Closed on: 2001-08-22 15:48:10
Description:
The test ioUtil-3.7 in tests/ioUtil.test has incorrect
bracing, it relies on bug #219184 to function properly.

The script

catch {
      catch [open testOpenFileChannel1%.fil r]
      catch [open testOpenFileChannel2%.fil r]
      catch [open testOpenFileChannel3%.fil r]
 } err5
 set err5

(where none of the channels exist) should return
   couldn't open "testOpenFileChannel1%.fil": no such
file or directory

and not 1: the first error is *not* [catch]ed. Due to
the above mentioned compiler bug, it is ...

I enclose a patch for review by the area maintainer.
User Comments: dgp added on 2001-08-22 22:48:10:
Logged In: YES 
user_id=80530

ioutil.patch applied to HEAD.

msofer added on 2001-08-22 22:42:51:
Logged In: YES 
user_id=148712

The [catch] bug is fixed, the test now fails on the HEAD.

vincentdarley added on 2001-08-22 18:26:49:
Logged In: YES 
user_id=32170

Looks better to me.  Feel free to apply.

dgp added on 2001-08-22 03:12:00:

File Added - 9800: ioutil.patch

Logged In: YES 
user_id=80530

Here's a patch that corrects the reported problem
and also improves the consistency of logic in the
ioUtil-3.X sequence of tests.

It does not correct the poor design of the test
sequence itself, with it's unmanaged interdependencies.
That will require a more substantial rewrite.

vincentdarley added on 2001-08-16 16:28:20:
Logged In: YES 
user_id=32170

Perhaps it should have been 'close [open ...]' 
not 'catch'?  I must say I really don't quite get what this 
test is trying to do.

dkf added on 2001-08-16 15:35:17:

File Added - 9592: patch451200_2.txt

Logged In: YES 
user_id=79902

Examination of the preceding tests indicates that the fix
ought to be a little bit more subtle.

dgp added on 2001-08-15 22:42:54:
Logged In: YES 
user_id=80530

Hmmm... I don't know why SF failed to auto-assign
this to the maintainer?  Manual assigning now...

msofer added on 2001-08-15 22:21:18:

File Added - 9568: patch451200.txt

Attachments: