From 2fd06148ba94057d3db3eb293a02727daa074887 Mon Sep 17 00:00:00 2001 From: Jared Wasinger Date: Thu, 27 Mar 2025 20:30:50 +0100 Subject: [PATCH] fix compile error --- eth/downloader/queue.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/eth/downloader/queue.go b/eth/downloader/queue.go index a9ba3156c3..39be90216a 100644 --- a/eth/downloader/queue.go +++ b/eth/downloader/queue.go @@ -375,10 +375,11 @@ func (q *queue) Results(block bool) []*fetchResult { results := q.resultCache.GetCompleted(maxResultsProcess) + var throttleThreshold uint64 if len(results) > 0 { // 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) - throttleThreshold := min(uint64(blockCacheMemory)/(gasLimit/10), 2048) + throttleThreshold = min(uint64(blockCacheMemory)/(gasLimit/10), 2048) throttleThreshold = q.resultCache.SetThrottleThreshold(throttleThreshold) }