Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: language lawyering: ftello/fseek/pread edition
On Mon, 23 Mar 2015, Thomas Klausner wrote:
Petri Hintukainen pointed out a problem in the NetBSD headers
about ftello/fseeko/pread:
https://mailman.videolan.org/pipermail/libbdplus-devel/2015-March/000039.html
Can someone please fix the issue, or explain why the argument is
wrong?
It's a little difficult to extract a problem report from that
message, because the message is oriented towards how a user can
achieve a desired result given what NetBSD is doing, rather than
how NetBSD should be changed to improve standards conformance.
I think the issue is: After #define _POSIX_C_SOURCE 200112L
and #include <stdio.h>, fseeko() and ftello() should be declared,
but in some unspecified version of NetBSD they are not declared.
Similarly, after #define _POSIX_C_SOURCE 200112L and #include
<unistd.h>, pread() and pwrite() should be declared but they are
not.
I agree that fseeko(), ftello(), pread(), and pwrite(), should
be declared when _POSIX_C_SOURCE >= 200112L. I see that
NetBSD-current fails to do so. The obvious addition of "||
(_POSIX_C_SOURCE - 0) >= 200112L" in appropriate places in stdio.h
and unistd.h should fix it.
--apb (Alan Barrett)
Home |
Main Index |
Thread Index |
Old Index