3
0
mirror of https://github.com/Qortal/altcoinj.git synced 2025-02-07 06:44:16 +00:00

Make PeerGroup.maxConnections fully synchronized.

This commit is contained in:
Mike Hearn 2012-07-22 01:22:56 +02:00
parent fd9eba1697
commit 5bae8ffe6c

View File

@ -211,12 +211,12 @@ public class PeerGroup {
}
/** The maximum number of connections that we will create to peers. */
public void setMaxConnections(int maxConnections) {
public synchronized void setMaxConnections(int maxConnections) {
this.maxConnections = maxConnections;
}
/** The maximum number of connections that we will create to peers. */
public int getMaxConnections() {
public synchronized int getMaxConnections() {
return maxConnections;
}