Force sending a FIN packet on rpcn disconnect

This commit is contained in:
RipleyTom 2023-12-13 04:34:17 +01:00 committed by Elad Ashkenazi
parent 75494066ea
commit f709a5747a

View File

@ -673,8 +673,10 @@ namespace rpcn
if (sockfd)
{
#ifdef _WIN32
::shutdown(sockfd, SD_BOTH);
::closesocket(sockfd);
#else
::shutdown(sockfd, SHUT_RDWR);
::close(sockfd);
#endif
sockfd = 0;