aboutsummaryrefslogtreecommitdiff
path: root/src/util/error.cpp
diff options
context:
space:
mode:
authorMartin Zumsande <mzumsande@gmail.com>2022-08-23 13:47:04 -0400
committerMartin Zumsande <mzumsande@gmail.com>2022-10-24 16:15:22 -0400
commit0565951f34e6d155dc825964c5d8b1dd00931682 (patch)
treef2e5135b346ebced80ba94859749bc734823e854 /src/util/error.cpp
parentd480586ecb1d4c265ffec278f10c46500d89382f (diff)
p2p: Make block stalling timeout adaptive
This makes the stalling detection mechanism (previously a fixed timeout of 2s) adaptive: If we disconnect a peer for stalling, double the timeout for the next peer - and let it slowly relax back to its default value each time the tip advances. (Idea by Pieter Wuille) This makes situations more unlikely in which we'd keep on disconnecting many of our peers for stalling, even though our own bandwidth is insufficient to download a block in 2 seconds. Co-authored-by: Vasil Dimov <vd@FreeBSD.org>
Diffstat (limited to 'src/util/error.cpp')
0 files changed, 0 insertions, 0 deletions