Changeset 2966 for pjproject/trunk/pjnath/src/pjnath/stun_sock.c
- Timestamp:
- Oct 25, 2009 9:02:07 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjnath/src/pjnath/stun_sock.c
r2667 r2966 137 137 cfg->async_cnt = 1; 138 138 cfg->ka_interval = PJ_STUN_KEEP_ALIVE_SEC; 139 cfg->qos_type = PJ_QOS_TYPE_BEST_EFFORT; 140 cfg->qos_ignore_error = PJ_TRUE; 139 141 } 140 142 … … 201 203 goto on_error; 202 204 205 /* Apply QoS, if specified */ 206 status = pj_sock_apply_qos2(stun_sock->sock_fd, cfg->qos_type, 207 &cfg->qos_params, 2, stun_sock->obj_name, 208 NULL); 209 if (status != PJ_SUCCESS && !cfg->qos_ignore_error) 210 goto on_error; 211 212 /* Bind socket */ 203 213 if (pj_sockaddr_has_addr(&cfg->bound_addr)) { 204 214 status = pj_sock_bind(stun_sock->sock_fd, &cfg->bound_addr, … … 759 769 /* Log socket error */ 760 770 if (status != PJ_SUCCESS) { 761 char errmsg[PJ_ERR_MSG_SIZE]; 762 763 pj_strerror(status, errmsg, sizeof(errmsg)); 764 PJ_LOG(2,(stun_sock->obj_name, "recvfrom() error: %s", errmsg)); 771 pj_perror(2, stun_sock->obj_name, status, "recvfrom() error", 0); 765 772 return PJ_TRUE; 766 773 }
Note: See TracChangeset
for help on using the changeset viewer.