Fix incorrect use of tr_timerAdd.
This commit is contained in:
parent
c5e3cfecb9
commit
98ea0addb0
|
@ -56,7 +56,7 @@ static void
|
|||
timer_callback(int s UNUSED, short type UNUSED, void *closure UNUSED)
|
||||
{
|
||||
UTP_CheckTimeouts();
|
||||
tr_timerAdd(utp_timer, 0, tr_cryptoWeakRandInt(2000000));
|
||||
tr_timerAdd(utp_timer, 1, tr_cryptoWeakRandInt(1000000));
|
||||
}
|
||||
|
||||
int
|
||||
|
@ -69,7 +69,7 @@ tr_utpPacket(const unsigned char *buf, size_t buflen,
|
|||
if(utp_timer == NULL)
|
||||
return -1;
|
||||
evtimer_set(utp_timer, timer_callback, NULL);
|
||||
tr_timerAdd(utp_timer, 0, tr_cryptoWeakRandInt(2000000));
|
||||
tr_timerAdd(utp_timer, 1, tr_cryptoWeakRandInt(1000000));
|
||||
}
|
||||
|
||||
return UTP_IsIncomingUTP(incoming, send_to, ss,
|
||||
|
|
Loading…
Reference in New Issue