[Gdal-dev] VSIFOpenL/VSIFOpen question
Eric Dönges
eric.doenges at gmx.net
Sat Oct 28 08:39:03 EDT 2006
Hi,
after spending about an hour or so debugging a heavily modified gdal
driver that kept crashing in the OS's sseek function, I realized that
my problem was that while VSIFOpenL
claims to return a FILE * (and all the related VSIFXXXL functions
claim to expect FILE *),
what it returns is not really a FILE *. I think this is an absolutely
horrid design
decision (and whoever thought it up should be thoroughly ashamed of
themselves). Wouldn't
it be better to create a new type name for these functions, for
instance VFILE (or VSIFILE
*)? That way, the compiler could warn naive programmers like me when
I pass the wrong type
of file handle. Or am I missing something important here ?
With kind regards,
Eric
P.S.: I'm probably going to regret this, but I'll volunteer to do the
necessary work to
fix this if the steering committee agrees that this needs to be fixed.
More information about the Gdal-dev
mailing list