Tighten resource constraints on CNode.
Limit CNode::mapAskFor #4878
pull laanwj wants to merge 2 commits into bitcoin:master from laanwj:2014_09_mapaskfor changing 3 files +9 −0-
laanwj commented at 7:21 AM on September 9, 2014: member
-
d4168c82be
Limit CNode::mapAskFor
Tighten resource constraints on CNode.
- laanwj added the label P2P on Sep 9, 2014
-
Avoid returning many "inv" orphans 540ac4514d
-
gmaxwell commented at 7:31 AM on September 9, 2014: contributor
ut ACK (started tests on it).
-
BitcoinPullTester commented at 8:07 AM on September 9, 2014: none
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/p4878_540ac4514dbe4e077917bad1750768218ef5f9cf/ for binaries and test log. This test script verifies pulls every time they are updated. It, however, dies sometimes and fails to test properly. If you are waiting on a test, please check timestamps to verify that the test.log is moving at http://jenkins.bluematt.me/pull-tester/current/ Contact BlueMatt on freenode if something looks broken.
-
in src/main.cpp:None in 540ac4514d
3638 | @@ -3639,6 +3639,11 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv, 3639 | 3640 | // Track requests for our stuff 3641 | g_signals.Inventory(inv.hash); 3642 | + 3643 | + if (pfrom->nSendSize > (SendBufferSize() * 2)) { 3644 | + Misbehaving(pfrom->GetId(), 50); 3645 | + return error("send buffer size() = %u", pfrom->nSendSize);
Diapolo commented at 8:27 AM on September 9, 2014:I'd suggest clarifying that error message a little.
laanwj commented at 8:32 AM on September 9, 2014:Right, it should have least the peer id
laanwj commented at 7:59 AM on September 10, 2014:The error is entirely consistent with other errors in ProcessMessage, so I'll keep it like this. The "misbehaving" message itself will already log more information about the peer.
laanwj merged this on Sep 10, 2014laanwj closed this on Sep 10, 2014laanwj referenced this in commit d6af9856b0 on Sep 10, 2014MarcoFalke locked this on Sep 8, 2021ContributorsLabels
This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-13 15:15 UTC
More mirrored repositories can be found on mirror.b10c.me