Changeset 721 for pjproject/trunk/pjsip/src/pjsip/sip_transport_udp.c
- Timestamp:
- Sep 14, 2006 6:51:01 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip/sip_transport_udp.c
r635 r721 653 653 */ 654 654 if (tmp_addr.sin_addr.s_addr == PJ_INADDR_ANY) { 655 pj_hostent he; 656 const pj_str_t *hostname = pj_gethostname(); 657 status = pj_gethostbyname(hostname, &he); 658 if (status != PJ_SUCCESS) { 659 pj_sock_close(sock); 655 pj_in_addr hostip; 656 657 status = pj_gethostip(&hostip); 658 if (status != PJ_SUCCESS) 660 659 return status; 661 } 662 pj_strcpy2(&bound_name.host, 663 pj_inet_ntoa(*(pj_in_addr*)he.h_addr)); 660 661 pj_strcpy2(&bound_name.host, pj_inet_ntoa(hostip)); 664 662 } else { 665 663 /* Otherwise use bound address. */
Note: See TracChangeset
for help on using the changeset viewer.