Re: seek() bug?

new topic     » goto parent     » topic index » view thread      » older message » newer message

On 15 Feb 2002, at 15:58, Robert Craig wrote:

> 
> Kat writes:
> > So is there a buglist for seek? 
> 
> There aren't any known bugs in seek().
> EDS uses seek() extensively, and there aren't 
> any known bugs in EDS either.
> 
> > Is seek() maybe allergic to long filenames, or 
> > filenames with sp aces in them? 
> 
> The file name is irrelevant to seek(), but
> there are some potential "gotchas".
> 
> 1. It's strongly recommended that you open the file in binary mode,
>     "rb", "wb" or "ub". (otherwise \r\n is secretly converted to \n by the
>     o/s,
>     and you'll go crazy trying to set the file position correctly)
> 
> 2. Opening in append mode, "a" is possibly a bit dicey. 
>     A bug was fixed in 2.3 official in that case because of
>     a Watcom bug.
> 
> 3. The Euphoria manual states:
>     "After seeking and reading (writing) a series of bytes, you may
>       need to call seek() explicitly before you switch to writing
>       (reading) bytes, even though the file position should already be
>       what you want."
> 
> If you can reduce the problem to something small, but runnable,
> and post it here, maybe we can see the problem.

I did, but you missed the ',' remember?

Kat

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu