On 09.01.25 20:18, Jacob Champion wrote:
> It'd be sad to copy-paste the API bug into a new place, though. If
> we're going to disconnect this API from SOCKET, can we use uintptr_t
> instead on Windows? If someone eventually adds an alternative to
> PQsocket(), as Tom suggested in [2], it'd be nice not to have to
> duplicate this callback too.
Assuming that uintptr_t is the right underlying type for SOCKET, that
seems ok.
But also note that
#ifdef WIN32
might not work because WIN32 is defined by the PostgreSQL build system,
not by the compiler (see src/include/port/win32.h).