Skip to content
This repository

break after ProcessMessage() to give other peers a chance. #2125

Closed
wants to merge 1 commit into from

4 participants

R E Broadley BitcoinPullTester Pieter Wuille Jeff Garzik
R E Broadley

This is to help with nodes becoming unresponsive in the eyes of other nodes. Also, in combination with my other pulls, this helps to reduce the number of duplicate blocks received.

BitcoinPullTester

Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/7f49bfde58ddf53611229ae2e0215fbea3b1425b for binaries and test log.

BitcoinPullTester

Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/7f49bfde58ddf53611229ae2e0215fbea3b1425b for binaries and test log.

Pieter Wuille
Collaborator
sipa commented

Can you test whether this is still needed, after the recent network changes?

Jeff Garzik
Collaborator

It seems unneeded, AFAICS

Pieter Wuille
Collaborator
sipa commented

Yes, I also don't see what this should help with, but rebroad seems to have unusual network problems of some sort, so I still wonder whether perhaps those improved because of the recent network changes.

R E Broadley
rebroad commented

@sipa yes, this still is useful after your network changes. This patch is still providing me with valuable functionality - especially when combined with #1382

Pieter Wuille
Collaborator
sipa commented

Can you explain what exact difference in behaviour you notice?

Jeff Garzik
Collaborator
jgarzik commented

@rebroad Agree w/ @sipa. Please explain precisely what behavior differences and problems are being seen.

"still useful" is insufficient :)

Jeff Garzik
Collaborator

Closing. Happy to reopen, if behavior differences can be specifically quantified.

Jeff Garzik jgarzik closed this
R E Broadley rebroad deleted the branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Dec 23, 2012
R E Broadley rebroad break after ProcessMessages() to give other peers a chance. 7f49bfd
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 3 additions and 1 deletion. Show diff stats Hide diff stats

  1. +3 1 src/main.cpp
4 src/main.cpp
@@ -3427,7 +3427,9 @@ bool ProcessMessages(CNode* pfrom)
3427 3427
3428 3428 if (!fRet)
3429 3429 printf("ProcessMessage(%s, %u bytes) FAILED\n", strCommand.c_str(), nMessageSize);
3430   - }
  3430 + else
  3431 + break; // give other peers a chance
  3432 + } // loop
3431 3433
3432 3434 vRecv.Compact();
3433 3435 return true;

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.