Skip to content

Commit 4697294

Browse files
committed
avoid closesocket redefine
1 parent 0bd57cf commit 4697294

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

base/hsocket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,11 @@ HV_INLINE int nonblocking(int s) {
8282
return fcntl(s, F_SETFL, fcntl(s, F_GETFL) | O_NONBLOCK);
8383
}
8484

85+
#ifndef closesocket
8586
HV_INLINE int closesocket(int sockfd) {
8687
return close(sockfd);
8788
}
89+
#endif
8890

8991
#endif
9092

0 commit comments

Comments
 (0)