bug: cygwin-devel v3.0.2-1 socket.h does not #define MSG_EOR per the POSIX standard
Eric Blake
eblake@redhat.com
Thu Apr 25 15:48:00 GMT 2019
On 4/25/19 10:28 AM, Brian Inglis wrote:
>> - add a define for MSG_EOR to a non-zero value that is bitwise distinct
>> from other required MSG_ values
>> - return EOPNOTSUPP on attempts to use the flag in
>> send()/sendmsg()/sendto() (POSIX permits that failure for protocols that
>> don't support it - and none of Cygwin's protocols support it)
>>
>> although I personally thought POSIX was clear enough that MSG_EOR is
>> required to be defined, even if only so that it can trigger send()
>> errors showing that it is unsupported.
>
> Would it be allowed and valid to #define MSG_EOR 0 to simplify lack of support?
No, because that implies that EVERY send() call is requesting MSG_EOR
and that it never fails. Defining it to a distinct non-zero value makes
it possible to report EOPNOTSUPP.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://cygwin.com/pipermail/cygwin/attachments/20190425/44890229/attachment.sig>
More information about the Cygwin
mailing list