fix compile error

This commit is contained in:
Jared Wasinger 2025-03-27 20:30:50 +01:00
parent c8f9d6bb90
commit 2fd06148ba

View file

@ -375,10 +375,11 @@ func (q *queue) Results(block bool) []*fetchResult {
results := q.resultCache.GetCompleted(maxResultsProcess) results := q.resultCache.GetCompleted(maxResultsProcess)
var throttleThreshold uint64
if len(results) > 0 { if len(results) > 0 {
// set a throttle threshhold based on estimated worst-sized block that can be created for a given gas limit. // set a throttle threshhold based on estimated worst-sized block that can be created for a given gas limit.
gasLimit := max(results[0].Header.GasLimit, 10) gasLimit := max(results[0].Header.GasLimit, 10)
throttleThreshold := min(uint64(blockCacheMemory)/(gasLimit/10), 2048) throttleThreshold = min(uint64(blockCacheMemory)/(gasLimit/10), 2048)
throttleThreshold = q.resultCache.SetThrottleThreshold(throttleThreshold) throttleThreshold = q.resultCache.SetThrottleThreshold(throttleThreshold)
} }