summaryrefslogtreecommitdiffstats
path: root/apps/openssl.c
diff options
context:
space:
mode:
authorDr. Matthias St. Pierre <matthias.st.pierre@ncp-e.com>2021-09-28 16:12:32 +0200
committerDr. Matthias St. Pierre <matthias.st.pierre@ncp-e.com>2021-09-30 14:03:16 +0200
commitf8dd5869bca047a23599ac925aace70efcf487ad (patch)
treeddec4cb0ec2ab9f4b84938fd4d2b4a81772c15db /apps/openssl.c
parent611685adc04a7c7e9612d51e743044fdcd9d1846 (diff)
doc/man3/SSL_set_fd.pod: add note about Windows compiler warning
According to an old stackoverflow thread [1], citing an even older comment by Andy Polyakov (1875e6db29, Pull up Win64 support from 0.9.8., 2005-07-05), a cast of 'SOCKET' (UINT_PTR) to 'int' does not create a problem, because although the documentation [2] claims that the upper limit is INVALID_SOCKET-1 (2^64 - 2), in practice the socket() implementation on Windows returns an index into the kernel handle table, the size of which is limited to 2^24 [3]. Add this note to the manual page to avoid unnecessary roundtrips to StackOverflow. [1] https://stackoverflow.com/questions/1953639/is-it-safe-to-cast-socket-to-int-under-win64 [2] https://docs.microsoft.com/en-us/windows/win32/winsock/socket-data-type-2 [3] https://docs.microsoft.com/en-us/windows/win32/sysinfo/kernel-objects Reviewed-by: Paul Dale <pauli@openssl.org> (Merged from https://github.com/openssl/openssl/pull/16699)
Diffstat (limited to 'apps/openssl.c')
0 files changed, 0 insertions, 0 deletions