Changeset 1671 for pjproject


Ignore:
Timestamp:
Jan 8, 2008 11:41:22 PM (17 years ago)
Author:
bennylp
Message:

Protect against division by zero in pjsua's dump_media_session (thanks Simon Farmer)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsua-lib/pjsua_call.c

    r1655 r1671  
    18791879        if (PJ_TIME_VAL_MSEC(media_duration) == 0) 
    18801880            media_duration.msec = 1; 
     1881 
     1882        /* protect against division by zero */ 
     1883        if (stat.rx.pkt == 0) 
     1884            stat.rx.pkt = 1; 
     1885        if (stat.tx.pkt == 0) 
     1886            stat.tx.pkt = 1; 
    18811887 
    18821888        len = pj_ansi_snprintf(p, end-p, 
Note: See TracChangeset for help on using the changeset viewer.