Changeset 6003 for pjproject/trunk/pjsip/src/pjsip/sip_transport_udp.c
- Timestamp:
- May 23, 2019 5:47:55 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip/sip_transport_udp.c
r5991 r6003 143 143 goto on_return; 144 144 145 #if defined(PJ_IPHONE_OS_HAS_MULTITASKING_SUPPORT) && \146 PJ_IPHONE_OS_HAS_MULTITASKING_SUPPORT!=0147 145 if (-bytes_read == PJ_ESOCKETSTOP) { 148 146 --tp->read_loop_spin; … … 162 160 return; 163 161 } 164 #endif165 162 166 163 /* … … 325 322 tdata_op_key->tdata = NULL; 326 323 327 #if defined(PJ_IPHONE_OS_HAS_MULTITASKING_SUPPORT) && \328 PJ_IPHONE_OS_HAS_MULTITASKING_SUPPORT!=0329 324 if (-bytes_sent == PJ_ESOCKETSTOP) { 330 325 pj_status_t status; … … 344 339 return; 345 340 } 346 #endif347 341 348 342 if (tdata_op_key->callback) { … … 386 380 rem_addr, addr_len); 387 381 388 if (status != PJ_EPENDING) 382 if (status != PJ_EPENDING) { 383 if (status == PJ_ESOCKETSTOP) { 384 /* Try to recover by restarting the transport. */ 385 PJ_LOG(4,(tp->base.obj_name, "Restarting SIP UDP transport")); 386 status = pjsip_udp_transport_restart2( 387 &tp->base, 388 PJSIP_UDP_TRANSPORT_DESTROY_SOCKET, 389 PJ_INVALID_SOCKET, 390 &tp->base.local_addr, 391 &tp->base.local_name); 392 393 if (status != PJ_SUCCESS) { 394 PJ_PERROR(1,(THIS_FILE, status, 395 "Error restarting SIP UDP transport")); 396 } 397 } 389 398 tdata->op_key.tdata = NULL; 399 } 390 400 391 401 return status;
Note: See TracChangeset
for help on using the changeset viewer.