Subject: read(), write() and ftell(), feof()
From: [email-masked] (Todd Waxahachiefortudinouslyexportitionismistically Hartman)

10 Jul 1998 01:29:44 -0700
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
To: [email-masked] (gnuwin32)

> Under win32 (nad also linux) when reading/writing to a file using
> read()/write() does not update the file pointer information so that functions
> like ftell() and feof() do not work properly. These functions do update the
> file pointers properly under Solaris and Unixware. What gives?
> 
> David Chazin

Is this behavior guaranteed under POSIX?  Why are you using read()/write()?
I don't think you can mix buffered and unbuffered I/O and expect things
to function properly.  If you don't want to use fread()/fwrite() with
streams, than you probably should forget about using the other functions
and macros that deal with the stream structure (FILE).

todd.

-- 
Todd Hartman           [email-masked]      (512)838-8789
The opinions which may or may not be explicitly expressed or implied in this
document are completely my own and are not necessarily those of my employer.
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".