[haiku-development] Re: posix_fallocate() not supported error code
- From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
- To: haiku-development@xxxxxxxxxxxxx
- Date: Mon, 20 Sep 2021 09:36:06 +0200
Hi Niels,
Am 20.09.2021 um 09:06 schrieb Niels Sascha Reedijk:
2. Fix at the posix_fallocate() in libroot, which will convert
B_NOT_SUPPORTED to a EOPNOTSUPP to be consistent with other platforms.
You mix B_NOT_SUPPORTED with B_UNSUPPORTED here -- the former already
maps to EOPNOTSUPP.
It does not make much sense to have both IMO. Since there is already a
POSIX error code, it seems useless to introduce our own.
So my suggestion would be to phase out B_UNSUPPORTED in favor of the
other error code. We could either just define it to B_NOT_SUPPORTED (for
source compatibility), or just remove it completely.
At least the GCC2 version of strerror() should continue to support the
old error code, though (as we inherited that one from BeOS), for binary
compatibility.
Bye,
Axel.
Other related posts: