Subject: Re: Semantics of lseek system call
To: None <current-users@netbsd.org>
From: der Mouse <mouse@Collatz.McRCIM.McGill.EDU>
List: current-users
Date: 12/01/1994 12:01:51
>> Trying to locate before the begin of a file is accepted without a
>> returning error.
> Interestingly, I just tried it under SunOS, and it succeeds without
> error.

How very odd.  When I tried it on SunOS, I got EINVAL.  I guess we need
to break it down by release - my test was under a "SunOS Release 4.1.2"
kernel.

> POSIX is ambiguous on the subject.

All you need to do is think of off_t as an unsigned type, and suddenly
there is no "before the begin[ning] of a file", only very large offsets
into a file. :-)

But I suppose that isn't very useful, because then L_INCR and L_XTND
can't take negative arguments. :-(

					der Mouse

			    mouse@collatz.mcrcim.mcgill.edu