summaryrefslogtreecommitdiff
path: root/pjlib/src/pj/sock_bsd.c
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2009-10-25 09:02:07 +0000
committerBenny Prijono <bennylp@teluu.com>2009-10-25 09:02:07 +0000
commitfdc0f2ecdb18b9176f87f55ee17f054ce107e8c7 (patch)
tree768b9507e60426fcabcc8b4ce2540ae727cf7ffa /pjlib/src/pj/sock_bsd.c
parent2053af19e76b9c13e8bdebb13669cf915dc49981 (diff)
Initial commit for ticket #950: QoS support:
- implementation: - PJLIB (sock_qos*.*) - added QoS support in: - SIP UDP transport, - SIP TCP transport, - media UDP transport (done in pjsua-lib), - pjnath ICE stream transport, - pjnath STUN socket, - pjnath TURN client - added QoS options in pjsua-lib: - QoS fields in pjsua_transport_config - added "--set-qos" parameter in pjsua Notes: - QoS in TLS transport is not yet implemented, waiting for #957 - build ok on VS6, VS2005 (multiple targets), Carbide, and Mingw - no run-time testing yet git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2966 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/src/pj/sock_bsd.c')
-rw-r--r--pjlib/src/pj/sock_bsd.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/pjlib/src/pj/sock_bsd.c b/pjlib/src/pj/sock_bsd.c
index 6cf24fe2..36761bce 100644
--- a/pjlib/src/pj/sock_bsd.c
+++ b/pjlib/src/pj/sock_bsd.c
@@ -63,7 +63,7 @@ const pj_uint16_t PJ_SOL_IP = SOL_IP;
#elif defined(PJ_WIN32) && PJ_WIN32
const pj_uint16_t PJ_SOL_IP = IPPROTO_IP;
#else
-const pj_uint16_t PJ_SOL_IP = 0xFFFF;
+const pj_uint16_t PJ_SOL_IP = 0;
#endif /* SOL_IP */
#if defined(SOL_TCP)
@@ -73,7 +73,7 @@ const pj_uint16_t PJ_SOL_TCP = IPPROTO_TCP;
#elif defined(PJ_WIN32) && PJ_WIN32
const pj_uint16_t PJ_SOL_TCP = IPPROTO_TCP;
#else
-const pj_uint16_t PJ_SOL_TCP = 0xFFFF;
+const pj_uint16_t PJ_SOL_TCP = 6;
#endif /* SOL_TCP */
#ifdef SOL_UDP
@@ -83,7 +83,7 @@ const pj_uint16_t PJ_SOL_UDP = IPPROTO_UDP;
#elif defined(PJ_WIN32) && PJ_WIN32
const pj_uint16_t PJ_SOL_UDP = IPPROTO_UDP;
#else
-const pj_uint16_t PJ_SOL_UDP = 0xFFFF;
+const pj_uint16_t PJ_SOL_UDP = 17;
#endif /* SOL_UDP */
#ifdef SOL_IPV6
@@ -95,7 +95,7 @@ const pj_uint16_t PJ_SOL_IPV6 = SOL_IPV6;
const pj_uint16_t PJ_SOL_IPV6 = 41;
# endif
#else
-const pj_uint16_t PJ_SOL_IPV6 = 0xFFFF;
+const pj_uint16_t PJ_SOL_IPV6 = 41;
#endif /* SOL_IPV6 */
/* IP_TOS */
@@ -135,6 +135,12 @@ const pj_uint16_t PJ_SO_RCVBUF = SO_RCVBUF;
const pj_uint16_t PJ_SO_SNDBUF = SO_SNDBUF;
const pj_uint16_t PJ_TCP_NODELAY= TCP_NODELAY;
const pj_uint16_t PJ_SO_REUSEADDR= SO_REUSEADDR;
+#if defined(SO_PRIORITY)
+const pj_uint16_t PJ_SO_PRIORITY = SO_PRIORITY;
+#else
+/* This is from Linux, YMMV */
+const pj_uint16_t PJ_SO_PRIORITY = 12;
+#endif
/* Multicasting is not supported e.g. in PocketPC 2003 SDK */
#ifdef IP_MULTICAST_IF