mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
FreeBSD compatibility
Seems we just need to take care about __FreeBSD__ along with __APPLE__ in a couple of places. Signed-off-by: Matthieu Riviere <matthieu.riviere@leukensis.org>
This commit is contained in:
parent
ea0642abb2
commit
5e1b7fff3a
1 changed files with 2 additions and 2 deletions
|
@ -12,7 +12,7 @@ struct libwebsocket *__libwebsocket_client_connect_2(
|
|||
int plen = 0;
|
||||
char pkt[512];
|
||||
int opt = 1;
|
||||
#if defined(__APPLE__)
|
||||
#if defined(__APPLE__) || defined(__FreeBSD__)
|
||||
struct protoent *tcp_proto;
|
||||
#endif
|
||||
|
||||
|
@ -63,7 +63,7 @@ struct libwebsocket *__libwebsocket_client_connect_2(
|
|||
bzero(&server_addr.sin_zero, 8);
|
||||
|
||||
/* Disable Nagle */
|
||||
#if !defined(__APPLE__)
|
||||
#if !defined(__APPLE__) && !defined(__FreeBSD__)
|
||||
setsockopt(wsi->sock, SOL_TCP, TCP_NODELAY,
|
||||
(const void *)&opt, sizeof(opt));
|
||||
#else
|
||||
|
|
Loading…
Add table
Reference in a new issue