diff options
Diffstat (limited to 'include/zbxsock.h')
-rwxr-xr-x | include/zbxsock.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/zbxsock.h b/include/zbxsock.h index 52b4834c..1b211f03 100755 --- a/include/zbxsock.h +++ b/include/zbxsock.h @@ -57,13 +57,15 @@ typedef struct sockaddr_in ZBX_SOCKADDR; -int zbx_sock_read(ZBX_SOCKET sock, void *buf, int buflen, int timeout); -int zbx_sock_write(ZBX_SOCKET sock, void *buf, int buflen); +int zbx_sock_read(ZBX_SOCKET sock, void *buf, int buflen, int timeout); +int zbx_sock_write(ZBX_SOCKET sock, void *buf, int buflen); #if defined (WIN32) + int zbx_sock_init(void); # define zbx_sock_close(sock) closesocket(sock) # define zbx_sock_last_error() WSAGetLastError() #else /* not WIN32 */ +# define zbx_sock_init() SUCCEED # define zbx_sock_close(sock) close(sock) # define zbx_sock_last_error() errno #endif /* WIN32 */ |