Changeset 251 for pjproject/trunk


Ignore:
Timestamp:
Mar 1, 2006 7:27:06 PM (19 years ago)
Author:
bennylp
Message:

Fixed bug in timer, where poll() can return negative time, causing havoc with other polling function that depends on the value

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjlib/src/pj/timer.c

    r193 r251  
    506506        *next_delay = ht->heap[0]->_timer_value; 
    507507        PJ_TIME_VAL_SUB(*next_delay, now); 
     508        if (next_delay->sec < 0 || next_delay->msec < 0) 
     509            next_delay->sec = next_delay->msec = 0; 
    508510    } else if (next_delay) { 
    509511        next_delay->sec = next_delay->msec = PJ_MAXINT32; 
Note: See TracChangeset for help on using the changeset viewer.