[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: datagram source port?
From: |
Robert Pluim |
Subject: |
Re: datagram source port? |
Date: |
Thu, 16 Jan 2020 09:04:08 +0100 |
>>>>> On Wed, 15 Jan 2020 18:27:38 +0200, Eli Zaretskii <address@hidden> said:
>> From: Robert Pluim <address@hidden>
>> Cc: address@hidden, address@hidden
>> Date: Wed, 15 Jan 2020 10:49:33 +0100
>>
>> I took another quick look at this, and noticed that the windows port
>> doesn't support datagram sockets at all, although the underlying
>> Winsock does. Is there a reason for that?
Eli> This comment from nt/inc/ms-w32.h explains that:
Eli> /* And the select implementation does 1-byte read-ahead waiting
Eli> for received packets, so datagrams are broken too. */
Eli> #define BROKEN_DATAGRAM_SOCKETS 1
Eek.
Eli> (Let me know if you want me to explain what it means by "1-byte
Eli> read-ahead". Or just read the large commentary that starts around
Eli> line 870 of w32proc.c.)
Eli> I don't know enough about datagram sockets, but I hope you do, in
Eli> which case the above comment ought to be the answer.
Yes, itʼs the answer. Some brave soul could no doubt rewrite the w32
select implementation to fix this, but thatʼs not me.
Robert