Changeset 5230 for pjproject


Ignore:
Timestamp:
Dec 31, 2015 5:25:45 AM (9 years ago)
Author:
ming
Message:

Re #1882 (misc): close socket on error after calling pj_sock_getsockname() as it was closed above on error after calling get_published_name()

Thanks to Dusan Klinec for the patch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsip/sip_transport_udp.c

    r5035 r5230  
    10911091        status = pj_sock_getsockname(sock, &tp->base.local_addr,  
    10921092                                     &tp->base.addr_len); 
    1093         if (status != PJ_SUCCESS) 
    1094             return status; 
     1093        if (status != PJ_SUCCESS) { 
     1094            pj_sock_close(sock); 
     1095            return status; 
     1096        } 
    10951097 
    10961098        /* Assign the socket and published address to transport. */ 
Note: See TracChangeset for help on using the changeset viewer.