On Tue, Mar 27, 2001 at 01:18:20PM -0800, Peter Jay Salzman wrote:
> it occurs to me that fsetpos and fseekpos aren't solutions, either.  simply
> because of all the code that's already out there that use fseek and ftell.

They're only solutions if you actually use them.  That's like saying
that penecillin isn't a solution, simply because of all the people who
don't use it.  It is your responsibility, as a programmer, to write
good tools, using what is given you.  During the time of K&R C,
fseek() and ftell() were the only thing going - you can't blame them
for using it.  But now, programmers are without excuse - if you expect
your program to work with files > 2G, you must use the better,
ANSI-provided solution (as opposed to K&R-provided).  In exactly the
same way that, with functions such as fgets() available, you are
without any excuse to use gets().

Certainly, fseek() and ftell() are to blame for the problem - but
rather than blame an innocent bystander, why not place the blame where
it belongs - K&R*?

* actually, they're not entirely to blame either, but I'm not about to
go into it.

> 
> peter (who is now going on to do something useful today).


Micah

Reply via email to