Changeset 3276


Ignore:
Timestamp:
Oct 3, 2007, 2:46:15 AM (15 years ago)
Author:
charles
Message:

fix peer-mgr.c:1092 asset failure reported by Waldorf_

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/peer-mgr.c

    r3275 r3276  
    10901090
    10911091    assert( t != NULL );
    1092     assert( !t->isRunning );
    1093     assert( t->reconnectTimer == NULL );
    1094     assert( t->rechokeTimer == NULL );
    1095 
    1096     t->isRunning = 1;
    1097     t->reconnectTimer = tr_timerNew( t->manager->handle, reconnectPulse, t, RECONNECT_PERIOD_MSEC );
    1098     t->rechokeTimer = tr_timerNew( t->manager->handle, rechokePulse, t, RECHOKE_PERIOD_MSEC );
     1092    assert( ( t->isRunning != 0 ) == ( t->reconnectTimer != NULL ) );
     1093    assert( ( t->isRunning != 0 ) == ( t->rechokeTimer != NULL ) );
     1094
     1095    if( !t->isRunning )
     1096    {
     1097        t->isRunning = 1;
     1098        t->reconnectTimer = tr_timerNew( t->manager->handle, reconnectPulse, t, RECONNECT_PERIOD_MSEC );
     1099        t->rechokeTimer = tr_timerNew( t->manager->handle, rechokePulse, t, RECHOKE_PERIOD_MSEC );
     1100    }
    10991101
    11001102    managerUnlock( manager );
Note: See TracChangeset for help on using the changeset viewer.