[comp.lang.icon] MS-DOS Problem

nowlin@iwtqg.att.com (11/10/90)

Here's a message I'm passing along for a friend.  He's having a problem
with Icon on MS-DOS and it doesn't have anything to do with memory this
time!  Any help would be appreciated.

===========================================================================

I think I've tripped on an honest to goodness bug in MS-DOS Icon for
Version 8.  I've been wrong on things like this before but here's what I
found last night.

I am reading in a PC-FILE database and processing it with V8 of Icon on an
AT&T 6300+ MS-DOS compatible computer.  The file is not too long - about
5000 bytes.  I start by reading in a number of fixed length (32 byte)
header records until I get to a record that starts with a newline
character.

Normally it would read 20-30 such 32-byte records.  But with V8 it read the
first and then the next:

	line := reads(fd,32)

returns not 32 characters but just 16 and a subsequent read attempt fails.
I presume with EOF.

A dump of the database file shows that the 49th character is an octal 032
which is the DOS CONTROL-Z or end-of-file marker.  What appears to be
happening is that V8 is stopping when it sees that CTL-Z.  V7 did not do
this!

The open was like:

	fd := open("TESTOFF.DBF","ru") | stop("DBF open failed")

and the open succeeds.

Joe T. Hall
(att!ihlpf!pax)