Ignore:
Timestamp:
Sep 23, 2019 10:47:05 PM (3 years ago)
Author:
riza
Message:

Close #2232: Crash on Endpoint::libDestroy() when there is an active call.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsua2/account.cpp

    r6068 r6074  
    968968{ 
    969969    if (isValid() && pjsua_get_state() < PJSUA_STATE_CLOSING) { 
     970#if !DEPRECATED_FOR_TICKET_2232 
    970971        // Cleanup buddies in the buddy list 
    971972        while(buddyList.size() > 0) { 
     
    973974            delete b; /* this will remove itself from the list */ 
    974975        } 
     976#endif 
    975977 
    976978        // This caused error message of "Error: cannot find Account.." 
     
    10651067} 
    10661068 
     1069#if !DEPRECATED_FOR_TICKET_2232 
    10671070const BuddyVector& Account::enumBuddies() const PJSUA2_THROW(Error) 
    10681071{ 
    10691072    return buddyList; 
    10701073} 
     1074#endif 
    10711075 
    10721076BuddyVector2 Account::enumBuddies2() const PJSUA2_THROW(Error) 
     
    10841088} 
    10851089 
     1090#if !DEPRECATED_FOR_TICKET_2232 
    10861091Buddy* Account::findBuddy(string uri, FindBuddyMatch *buddy_match) const 
    10871092                PJSUA2_THROW(Error) 
     
    10981103    PJSUA2_RAISE_ERROR(PJ_ENOTFOUND); 
    10991104} 
     1105#endif 
    11001106 
    11011107Buddy Account::findBuddy2(string uri) const PJSUA2_THROW(Error) 
     
    11171123void Account::addBuddy(Buddy *buddy) 
    11181124{ 
     1125#if !DEPRECATED_FOR_TICKET_2232 
    11191126    pj_assert(buddy); 
    11201127 
    11211128    buddyList.push_back(buddy); 
     1129#else 
     1130    PJ_UNUSED_ARG(buddy); 
     1131#endif 
    11221132} 
    11231133 
    11241134void Account::removeBuddy(Buddy *buddy) 
    11251135{ 
     1136#if !DEPRECATED_FOR_TICKET_2232 
    11261137    pj_assert(buddy); 
    11271138 
     
    11351146 
    11361147    pj_assert(!"Bug! Buddy to be removed is not in the buddy list!"); 
    1137 } 
     1148#else 
     1149    PJ_UNUSED_ARG(buddy); 
     1150#endif 
     1151} 
Note: See TracChangeset for help on using the changeset viewer.