Changeset 3830


Ignore:
Timestamp:
Oct 19, 2011 1:08:14 PM (12 years ago)
Author:
bennylp
Message:

Renamed enum names to comply with the spec in ticket (re #1216)

Location:
pjproject/branches/1.x
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • pjproject/branches/1.x/pjsip-apps/src/pjsua/pjsua_app.c

    r3829 r3830  
    51195119    } 
    51205120 
    5121     status = pjsua_destroy2(1); 
     5121    status = pjsua_destroy(); 
    51225122 
    51235123    pj_bzero(&app_config, sizeof(app_config)); 
  • pjproject/branches/1.x/pjsip/include/pjsua-lib/pjsua.h

    r3829 r3830  
    13001300{ 
    13011301    /** 
    1302      * Do not invoke any networking functions. 
    1303      */ 
    1304     PJSUA_DESTROY_NO_NETWORK = 1 
     1302     * Allow sending outgoing messages (such as unregistration, event 
     1303     * unpublication, BYEs, unsubscription, etc.), but do not wait for 
     1304     * responses. This is useful to perform "best effort" clean up 
     1305     * without delaying the shutdown process waiting for responses. 
     1306     */ 
     1307    PJSUA_DESTROY_NO_RX_MSG = 1, 
     1308 
     1309    /** 
     1310     * If this flag is set, do not send any outgoing messages at all. 
     1311     * This flag is useful if application knows that the network which 
     1312     * the messages are to be sent on is currently down. 
     1313     */ 
     1314    PJSUA_DESTROY_NO_TX_MSG = 2, 
     1315 
     1316    /** 
     1317     * Do not send or receive messages during destroy. This flag is 
     1318     * shorthand for  PJSUA_DESTROY_NO_RX_MSG + PJSUA_DESTROY_NO_TX_MSG. 
     1319     */ 
     1320    PJSUA_DESTROY_NO_NETWORK = PJSUA_DESTROY_NO_RX_MSG | 
     1321                               PJSUA_DESTROY_NO_TX_MSG 
    13051322 
    13061323} pjsua_destroy_flag; 
  • pjproject/branches/1.x/pjsip/src/pjsua-lib/pjsua_core.c

    r3829 r3830  
    13061306 
    13071307        /* Terminate all calls. */ 
    1308         if ((flags & PJSUA_DESTROY_NO_NETWORK) == 0) { 
     1308        if ((flags & PJSUA_DESTROY_NO_TX_MSG) == 0) { 
    13091309            pjsua_call_hangup_all(); 
    13101310        } 
     
    13361336        } 
    13371337         
    1338         /* No need to wait if we didn't send anything */ 
    1339         if (flags & PJSUA_DESTROY_NO_NETWORK) { 
     1338        /* No waiting if RX is disabled */ 
     1339        if (flags & PJSUA_DESTROY_NO_RX_MSG) { 
    13401340            max_wait = 0; 
    13411341        } 
     
    13701370                continue; 
    13711371 
    1372             if (pjsua_var.acc[i].regc && (flags & PJSUA_DESTROY_NO_NETWORK)==0) 
     1372            if (pjsua_var.acc[i].regc && (flags & PJSUA_DESTROY_NO_TX_MSG)==0) 
    13731373            { 
    13741374                pjsua_acc_set_registration(i, PJ_FALSE); 
     
    13961396        } 
    13971397         
    1398         /* No need to wait if we didn't send anything */ 
    1399         if (flags & PJSUA_DESTROY_NO_NETWORK) { 
     1398        /* No waiting if RX is disabled */ 
     1399        if (flags & PJSUA_DESTROY_NO_RX_MSG) { 
    14001400            max_wait = 0; 
    14011401        } 
     
    14211421         * transports shutdown to complete:  
    14221422         */ 
    1423         if (i < 20 && (flags & PJSUA_DESTROY_NO_NETWORK) == 0) { 
     1423        if (i < 20 && (flags & PJSUA_DESTROY_NO_RX_MSG) == 0) { 
    14241424            busy_sleep(1000 - i*50); 
    14251425        } 
  • pjproject/branches/1.x/pjsip/src/pjsua-lib/pjsua_pres.c

    r3829 r3830  
    12851285        acc->online_status = PJ_FALSE; 
    12861286 
    1287         if ((flags & PJSUA_DESTROY_NO_NETWORK) == 0) { 
     1287        if ((flags & PJSUA_DESTROY_NO_TX_MSG) == 0) { 
    12881288            send_publish(acc->index, PJ_FALSE); 
    12891289        } 
     
    13231323        pjsip_pres_set_status(uapres->sub, &pres_status); 
    13241324 
    1325         if ((flags & PJSUA_DESTROY_NO_NETWORK) == 0) { 
     1325        if ((flags & PJSUA_DESTROY_NO_TX_MSG) == 0) { 
    13261326            if (pjsip_pres_notify(uapres->sub, 
    13271327                                  PJSIP_EVSUB_STATE_TERMINATED, NULL, 
     
    22822282    } 
    22832283 
    2284     if ((flags & PJSUA_DESTROY_NO_NETWORK) == 0) { 
     2284    if ((flags & PJSUA_DESTROY_NO_TX_MSG) == 0) { 
    22852285        refresh_client_subscriptions(); 
    22862286 
Note: See TracChangeset for help on using the changeset viewer.