nfs4: make sure retry delay won't get out of bigtime_t range
This commit is contained in:
parent
75ff6e996f
commit
968cf7c83d
@ -17,6 +17,8 @@
|
||||
static inline bigtime_t
|
||||
RetryDelay(uint32 attempt, uint32 leaseTime = 0)
|
||||
{
|
||||
attempt = min_c(attempt, sizeof(bigtime_t) * 8);
|
||||
|
||||
bigtime_t delay = (1 << (attempt - 1)) * 100000;
|
||||
if (leaseTime != 0)
|
||||
delay = min_c(delay, sSecToBigTime(leaseTime));
|
||||
|
Loading…
Reference in New Issue
Block a user