RE: Curl_poll and Windows
Date: Thu, 21 Nov 2019 15:45:06 +0100 (CET)
On Tue, 19 Nov 2019, Jeff Mears wrote:
>> We'll happily welcome patches that improve libcurl, in this area as well as
>> others! This is all news to me and yet I've toyed with these things for a
>> while... albeit, not much on Windows.
>
> Sure, I'll consider it. The only issue that comes to mind is, in curl-land,
> how would I malloc() memory that is aligned to at least _Alignof(SOCKET)?
> I suppose that this ought to happen automatically if the hosting
> application's malloc is sane.
malloc is defined [1] to return memory aligned for this:
"The pointer returned if the allocation succeeds shall be suitably aligned so
that it may be assigned to a pointer to any type of object and then used to
access such an object"
[1] = https://pubs.opengroup.org/onlinepubs/009695399/functions/malloc.html
-- / daniel.haxx.se | Get the best commercial curl support there is - from me | Private help, bug fixes, support, ports, new features | https://www.wolfssl.com/contact/ ------------------------------------------------------------------- Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.htmlReceived on 2019-11-21