Skip to content

Conversation

@ghost
Copy link

@ghost ghost commented Aug 1, 2015

Currently, there are several integer literals of value 125 used to represent the maximum number of peer connections to maintain. This commit replaces those literals with a single constant defined in net.h.

@ghost ghost changed the title Consolidate individual references to the current maximum peer connection Consolidate disparate max peer connection values into single declaration. Aug 1, 2015
@ghost ghost changed the title Consolidate disparate max peer connection values into single declaration. Consolidate scattered max peer connection values into single declaration. Aug 1, 2015
@jonasschnelli
Copy link
Contributor

utACK.

@ghost
Copy link
Author

ghost commented Aug 1, 2015

I forget by whom, but wasn't there a previous recent effort to consolidate all constants into a single consensus header?

@sipa
Copy link
Member

sipa commented Aug 1, 2015

@NanoAkron This is just a network implementation constant, definitely not something consensus critical.

@laanwj
Copy link
Member

laanwj commented Aug 3, 2015

Looks good to me.
utACK

src/net.h Outdated
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A more consistent (and correct) name would be DEFAULT_MAX_PEER_CONNECTIONS

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed

@laanwj
Copy link
Member

laanwj commented Aug 3, 2015

Similar to #6349 (but affects a different value)

@fanquake
Copy link
Member

fanquake commented Aug 3, 2015

utACK

value of 125 into a single constant declaration.
@sipa
Copy link
Member

sipa commented Aug 4, 2015

utACK

@sipa sipa merged commit 19dd40a into bitcoin:master Aug 4, 2015
sipa added a commit that referenced this pull request Aug 4, 2015
19dd40a Consolidate individual references to the current maximum peer connection value of 125 into a single constant declaration. (Matt Quinn)
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants