mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 03:40:34 +02:00
socket: TCP_CORK, TCP_NODELAY
* libguile/socket.c (scm_init_socket): Define TCP_NODELAY and TCP_CORK if they are available. * doc/ref/posix.texi (Network Sockets and Communication): Add documentation. * NEWS: Add entry.
This commit is contained in:
parent
9454068a54
commit
d7f39a36b1
3 changed files with 21 additions and 0 deletions
|
@ -40,6 +40,7 @@
|
|||
#include <sys/un.h>
|
||||
#endif
|
||||
#include <netinet/in.h>
|
||||
#include <netinet/tcp.h>
|
||||
#include <netdb.h>
|
||||
#include <arpa/inet.h>
|
||||
|
||||
|
@ -1713,6 +1714,14 @@ scm_init_socket ()
|
|||
scm_c_define ("MSG_DONTROUTE", scm_from_int (MSG_DONTROUTE));
|
||||
#endif
|
||||
|
||||
/* TCP options. */
|
||||
#ifdef TCP_NODELAY
|
||||
scm_c_define ("TCP_NODELAY", scm_from_int (TCP_NODELAY));
|
||||
#endif
|
||||
#ifdef TCP_CORK
|
||||
scm_c_define ("TCP_CORK", scm_from_int (TCP_CORK));
|
||||
#endif
|
||||
|
||||
#ifdef IP_ADD_MEMBERSHIP
|
||||
scm_c_define ("IP_ADD_MEMBERSHIP", scm_from_int (IP_ADD_MEMBERSHIP));
|
||||
scm_c_define ("IP_DROP_MEMBERSHIP", scm_from_int (IP_DROP_MEMBERSHIP));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue