Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!elroy.jpl.nasa.gov!decwrl!pa.dec.com!src.dec.com!kalsow From: kalsow (Bill Kalsow) Newsgroups: comp.lang.modula3 Subject: 1.6 bugs Message-ID: <9104052014.AA07375@jumbo.pa.dec.com> Date: 5 Apr 91 20:14:04 GMT Lines: 46 To: m3 Cc: kalsow The following bugs have been reported in version 1.6: 1. FileStream.OpenRead(x) aborts with an assertion failure when x names a directory. It should return a reader on the underlying file. Fix: in system/corelib/filerw/UFileRdWr.m3, in CreateFileWriter line 356, change <*ASSERT FALSE*> to RAISE Failure (openFailure); in CreateFileReader line 386, change CoreOS.SIFREG => to CoreOS.SIFREG, CoreOS.SIFDIR => in CreateFileReader line 389, change <*ASSERT FALSE*> to RAISE Failure (openFailure); 2. Multi-threaded programs may deadlock while terminating when there's a thread blocked in a select on stdin. The problem is that RTMisc.Exit calls its registered cleanup routines. Stdio registers a cleanup routine that calls Rd.Close. It tries to lock the mutex in Stdio.stdin, but the reading thread already has the lock. The runtime doesn't recognize this as a deadlock since the select could return at any time. This problem is especially obnoxious when the program is trying to abort. 3. Formatter.Align was changed to take an object instead of a (procedure, REFANY) pair. Formatter.m3 was incompletely updated. This bug will cause assertion failures in programs that use Formatter (e.g. m3pp). Fix: in libs/misc/formatter/Formatter.m3, in the main body, line 1069, change DefineOp (PrintAlign, 5, 11) to DefineOp (PrintAlign, 4, 11) 4. In spite of their signatures, some routines in Rd don't raise Thread.Alerted. Fix: in system/corelib/filerw/UFileRdWr.m3, in TerminalReaderSeek link 262, change RTScheduler.IOSelect to RTScheduler.IOAlertSelect Thanks to Norman Ramsey and David Nichols for reporting these bugs. - Bill Kalsow