Module: kamailio Branch: master Commit: 094613b85d21e430fe9350722a99794bb2ae59bf URL: https://github.com/kamailio/kamailio/commit/094613b85d21e430fe9350722a99794b...
Author: Camille Oudot camille.oudot@orange.com Committer: Camille Oudot camille.oudot@orange.com Date: 2016-01-29T16:23:33+01:00
Merge pull request #491 from mslehto/bsdtcpops
Make tcpops module usable on BSD
---
Modified: modules/tcpops/doc/functions.xml Modified: modules/tcpops/doc/tcpops.xml Modified: tcp_options.h
---
Diff: https://github.com/kamailio/kamailio/commit/094613b85d21e430fe9350722a99794b... Patch: https://github.com/kamailio/kamailio/commit/094613b85d21e430fe9350722a99794b...
---
diff --git a/modules/tcpops/doc/functions.xml b/modules/tcpops/doc/functions.xml index b7b9842..937018a 100644 --- a/modules/tcpops/doc/functions.xml +++ b/modules/tcpops/doc/functions.xml @@ -18,7 +18,7 @@ <para>Meaning of the parameters is as follows:</para> <itemizedlist> <listitem> - <para><emphasis>conid</emphasis> (optionnal): the Kamailio internal + <para><emphasis>conid</emphasis> (optional): the Kamailio internal connection id (as in the <emphasis>$conid</emphasis> pseudovariable). </para> </listitem> @@ -48,7 +48,7 @@ <para>Meaning of the parameters is as follows:</para> <itemizedlist> <listitem> - <para><emphasis>conid</emphasis> (optionnal): the Kamailio internal + <para><emphasis>conid</emphasis> (optional): the Kamailio internal connection id (as in the <emphasis>$conid</emphasis> pseudovariable). </para> </listitem> @@ -83,7 +83,7 @@ <para>Meaning of the parameters is as follows:</para> <itemizedlist> <listitem> - <para><emphasis>conid</emphasis> (optionnal): the kamailio internal + <para><emphasis>conid</emphasis> (optional): the kamailio internal connection id on which TCP keepalive will be enabled. If no parameter is given, the keepalive mechanism will be enabled on the current message source connection. @@ -140,7 +140,7 @@ onreply_route[foo] { <para>Meaning of the parameters is as follows:</para> <itemizedlist> <listitem> - <para><emphasis>conid</emphasis> (optionnal): the kamailio internal + <para><emphasis>conid</emphasis> (optional): the kamailio internal connection id on which TCP keepalive will be disabled. If no parameter is given, the keepalive mechanism will be disabled on the current message source connection. @@ -181,7 +181,7 @@ onreply_route[foo] { <para>Meaning of the parameters is as follows:</para> <itemizedlist> <listitem> - <para><emphasis>conid</emphasis> (optionnal): the kamailio internal + <para><emphasis>conid</emphasis> (optional): the kamailio internal connection id on which to set the new lifetime. If no parameter is given, it will be set on the current message source connection. </para> diff --git a/modules/tcpops/doc/tcpops.xml b/modules/tcpops/doc/tcpops.xml index f142b7d..e4137e0 100644 --- a/modules/tcpops/doc/tcpops.xml +++ b/modules/tcpops/doc/tcpops.xml @@ -45,7 +45,7 @@ <para> <emphasis>Note</emphasis>: the keepalive functions only work on systems with the HAVE_TCP_KEEPIDLE, HAVE_TCP_KEEPCNT and HAVE_TCP_KEEPINTVL macros defined - (currently only Linux). + (Linux, FreeBSD, DragonFly BSD, NetBSD). </para> </section>
diff --git a/tcp_options.h b/tcp_options.h index f3b181d..d8da5f3 100644 --- a/tcp_options.h +++ b/tcp_options.h @@ -23,6 +23,7 @@
#ifdef USE_TCP
+#include <netinet/tcp.h> #ifndef NO_TCP_ASYNC #define TCP_ASYNC /* enabled async mode */ #endif @@ -74,24 +75,24 @@
/* keepintvl */ #ifndef NO_TCP_KEEPINTVL -#ifdef __OS_linux +#ifdef TCP_KEEPINTVL #define HAVE_TCP_KEEPINTVL -#endif /* __OS_ */ -#endif /* NO_TCP_KEEPIDLE */ +#endif /* TCP_KEEPINTVL */ +#endif /* NO_TCP_KEEPINTVL */
/* keepidle */ #ifndef NO_TCP_KEEPIDLE -#ifdef __OS_linux +#ifdef TCP_KEEPIDLE #define HAVE_TCP_KEEPIDLE -#endif /* __OS_*/ +#endif /* TCP_KEEPIDLE*/ #endif /* NO_TCP_KEEPIDLE */
/* keepcnt */ #ifndef NO_TCP_KEEPCNT -#ifdef __OS_linux +#ifdef TCP_KEEPCNT #define HAVE_TCP_KEEPCNT -#endif /* __OS_ */ +#endif /* TCP_KEEPCNT */ #endif /* NO_TCP_KEEPCNT */