mirror of
https://github.com/git/git.git
synced 2026-03-15 11:10:07 +01:00
Merge branch 'js/mingw-shutdown' into next
* js/mingw-shutdown: Windows: add a wrapper for the shutdown() system call
This commit is contained in:
@@ -1381,6 +1381,13 @@ int mingw_setsockopt(int sockfd, int lvl, int optname, void *optval, int optlen)
|
||||
return setsockopt(s, lvl, optname, (const char*)optval, optlen);
|
||||
}
|
||||
|
||||
#undef shutdown
|
||||
int mingw_shutdown(int sockfd, int how)
|
||||
{
|
||||
SOCKET s = (SOCKET)_get_osfhandle(sockfd);
|
||||
return shutdown(s, how);
|
||||
}
|
||||
|
||||
#undef listen
|
||||
int mingw_listen(int sockfd, int backlog)
|
||||
{
|
||||
|
||||
@@ -217,6 +217,9 @@ int mingw_bind(int sockfd, struct sockaddr *sa, size_t sz);
|
||||
int mingw_setsockopt(int sockfd, int lvl, int optname, void *optval, int optlen);
|
||||
#define setsockopt mingw_setsockopt
|
||||
|
||||
int mingw_shutdown(int sockfd, int how);
|
||||
#define shutdown mingw_shutdown
|
||||
|
||||
int mingw_listen(int sockfd, int backlog);
|
||||
#define listen mingw_listen
|
||||
|
||||
|
||||
Reference in New Issue
Block a user