Mail Archives: djgpp-workers/2000/11/29/23:03:52
At 10:13 AM 11/29/00 +0200, Eli Zaretskii wrote:
>On Tue, 28 Nov 2000, Peter J. Farley III wrote:
>
>> Ah! I misunderstood. Then, how about just the part of the comment
>> that the value for 21h/33 was changed from EPERM to EACCES for
>> fcntl? Is that more appropriate?
>
>That's exactly what I had in mind.
OK, will do.
<Snipped>
>> Well, I think on systems that support large files, type "off_t" is
>> probably a "long long", whatever that means on those systems.
>
>No, I don't think so. Changing off_t to long long would break lots
of
>existing code which assumes off_t and ssize_t are compatible.
Well, if that's the case then I don't know what else to say. Obviously
we *can* widen them, but I don't have the expertise to say if we
*should* do so. What we need here is someone with experience on a
system that actually has the capability.
>>>> How would one go about determining whether an arbitrary
>>>> combination "covered the whole file"?
>>>
>>> You use lseek to seek to the starting offset, then look at lseek's
>>> return value and compare it with zero. Then you lseek to the end
>>> of the region and compare lseek's return value with the result of
>>> "lseek(fd,0,SEEK_END);".
>>
>> I also assume you meant to say "llseek" there, right?
>
>Yes.
Thanks for the confirmation. Well, If we are going to allow F_RDLCK's
that cover the whole file, I guess that's not too much code to add. I
won't add it until we determine whether we should do them at
all. (Please see my other reply on this).
---------------------------------------------------------
Peter J. Farley III (pjfarley AT dorsai DOT org OR
pjfarley AT banet DOT net)
- Raw text -