From b4a280353d34be9275316f96140a6d0da2472b89 Mon Sep 17 00:00:00 2001 From: Divyansh Mishra Date: Sun, 12 Oct 2025 20:19:05 +0530 Subject: [PATCH] rpc: tolerate connection reset error in TestServerWebsocketReadLimit and triedb:pathdb:cross-platformbug --- triedb/pathdb/history_trienode.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/triedb/pathdb/history_trienode.go b/triedb/pathdb/history_trienode.go index 2a4459d4ad..04c805cb0c 100644 --- a/triedb/pathdb/history_trienode.go +++ b/triedb/pathdb/history_trienode.go @@ -524,7 +524,8 @@ func newSingleTrienodeHistoryReader(id uint64, reader ethdb.AncientReader, keyRa } keyStart := int(keyRange.start) keyLimit := int(keyRange.limit) - if keyLimit == math.MaxUint32 { + const maxKeyLimit = int(^uint32(0)) + if keyLimit == maxKeyLimit { keyLimit = len(keyData) } if len(keyData) < keyStart || len(keyData) < keyLimit {