Changeset 2258 for pjproject/trunk


Ignore:
Timestamp:
Sep 2, 2008 7:40:34 AM (16 years ago)
Author:
bennylp
Message:

Fixed ticket #607: Assertion and possibly crash in ICE stream transport when client is not behind NAT (thanks Nicolas Fauvel for the report)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjnath/src/pjnath/ice_strans.c

    r2195 r2258  
    12881288                if (dup) { 
    12891289                    /* Duplicate found, remove the srflx candidate */ 
     1290                    unsigned idx = cand - comp->cand_list; 
     1291 
     1292                    /* Update default candidate index */ 
     1293                    if (comp->default_cand > idx) { 
     1294                        --comp->default_cand; 
     1295                    } else if (comp->default_cand == idx) { 
     1296                        comp->default_cand = 0; 
     1297                    } 
     1298 
     1299                    /* Remove srflx candidate */ 
    12901300                    pj_array_erase(comp->cand_list, sizeof(comp->cand_list[0]), 
    1291                                    comp->cand_cnt, cand - comp->cand_list); 
     1301                                   comp->cand_cnt, idx); 
    12921302                    --comp->cand_cnt; 
    12931303                } else { 
Note: See TracChangeset for help on using the changeset viewer.