mirror of
https://github.com/byteworksinc/ORCA-C.git
synced 2024-12-21 16:29:31 +00:00
Update release notes and header to reflect recent stdio fixes.
This commit is contained in:
parent
06bf0c5f46
commit
f6fedea288
@ -61,7 +61,7 @@ typedef struct __file {
|
||||
*_end; /* end of the file buffer */
|
||||
unsigned long _size, /* size of the file buffer */
|
||||
_cnt; /* # chars that can be read/written to buffer */
|
||||
int _pbk; /* put back buffer */
|
||||
int _pbk[2]; /* put back buffer */
|
||||
unsigned int _flag, /* buffer flags */
|
||||
_file; /* GS/OS file ID */
|
||||
} FILE;
|
||||
@ -80,6 +80,7 @@ typedef struct __file {
|
||||
#define _IOERR 0x0100 /* has an error occurred? */
|
||||
#define _IOTEXT 0x0200 /* is this file a text file? */
|
||||
#define _IOTEMPFILE 0x0400 /* was this file created by tmpfile()? */
|
||||
#define _IOAPPEND 0x0800 /* is this file open in append mode? */
|
||||
|
||||
extern FILE *stderr; /* standard I/O files */
|
||||
extern FILE *stdin;
|
||||
|
30
cc.notes
30
cc.notes
@ -314,6 +314,10 @@ The discussion of abort() should note that it will call raise(SIGABRT) before ex
|
||||
|
||||
p. 356
|
||||
|
||||
fgetpos() and fsetpos() actually set errno to EIO if there is an error.
|
||||
|
||||
p. 359
|
||||
|
||||
The fprintf() family of functions has been updated to support several new features specified by C99. Also, the snprintf() and vsnprintf() functions have been added. See "Library Updates," below.
|
||||
|
||||
p. 367
|
||||
@ -348,6 +352,8 @@ p. 405
|
||||
|
||||
The discussion of _toupper should note that _toupper is an extension to ANSI C.
|
||||
|
||||
ORCA/C's implementation of ungetc() actually uses a two-character putback buffer for each stream, so ungetc() can be successfully called two times in a row.
|
||||
|
||||
p. 406
|
||||
|
||||
va_end is now a macro, not a function. Also, the va_arg, va_end, and va_start macros will now work even if stack repair code is enabled.
|
||||
@ -1831,6 +1837,30 @@ int foo(int[42]);
|
||||
|
||||
190. Calling rewind() should clear the I/O error indicator for the stream (the value returned by ferror()), but it was not doing so.
|
||||
|
||||
191. If a call like fseek(f, N, SEEK_CUR) was used on a file opened in read mode, it would not seek to the correct location, and in some cases it would set the error indicator for the stream, causing further operations on it to fail.
|
||||
|
||||
(Norman Dodge, Devin Reade)
|
||||
|
||||
192. If a file is opened in append mode (using 'a' in the mode argument to fopen), then all writes should be forced to the end of the file, regardless of any prior calls to positioning functions like fseek.
|
||||
|
||||
193. The ungetc() function did not work on character values 0x80 through 0xFF.
|
||||
|
||||
(Soenke Behrens)
|
||||
|
||||
194. A successful call to ungetc() should clear the end-of-file indicator for the stream.
|
||||
|
||||
195. fread() would discard characters put back with ungetc().
|
||||
|
||||
(Soenke Behrens)
|
||||
|
||||
196. fread() would generally return the wrong value if it was reading from stdin and the specified element size was anything other that 1.
|
||||
|
||||
197. If fread() was used on a file after data had been read from it using a different <stdio.h> function, fread() might not read the correct data.
|
||||
|
||||
198. Calling ftell() or fgetpos() on a file opened in read mode could cause subsequent reads to return data from the wrong position in the file.
|
||||
|
||||
199. If a file is open for reading and writing, it should be possible to read from it until end-of-file is encountered and then immediately write to it, but an error would be reported when the write was attempted.
|
||||
|
||||
-- Bugs from C 2.1.0 that have been fixed -----------------------------------
|
||||
|
||||
1. In some situations, fread() reread the first 1K or so of the file.
|
||||
|
Loading…
Reference in New Issue
Block a user