🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Ken Richardson Sat, 19 Dec 1992 20:52
Is _IOFBF dysfunctional in gcc/g++?
#1571
Author: Ken Richardson
Date: Sat, 19 Dec 1992 20:52
24 lines
1742 bytes
I need to use buffered file I/O for performance, but _IOFBF isn't defined in
stdio.h (as I received it on the standard distribution from miami.edu).

I found the definition for _IOFBF as "02" from an old version of GCC (version
1.something - I don't remember exactly), and it sort-of works.  But it's
slightly buggy, for example sometimes not reading all the file data on input,
and always writing extra buffer space on output, without a correct EOF
indication. These problems didn't exist on the older version of gcc that I
upgraded to 2.2.2.

I can work around the problem by dropping the setvbuf/_IOFBF call, but that
increases my file I/O by a factor of 100.  :-(

I'm using GCC 2.2.2 on VMS as distributed by mango.rsmas.miami.edu.  :-)
I'm using the /plus compiler option, as I'm using some C++ features.

I would greatly appreciate your help; email is fine.
If any interest is expressed, I will gladly summarize.  Thanks.
--
------------------------------------------------------------------------------
 Ken Richardson  | SyCraft Software | When wealth is lost, nothing is lost;
 ken@sycraft.com | Colorado Springs | when health is lost, something is lost;
                 | CO, USA          | when character is lost, all is lost.
------------------------------------------------------------------------------
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads