mirror of
https://github.com/Qortal/altcoinj.git
synced 2025-02-11 17:55:53 +00:00
PeerGroup.startBlockChainDownload(): add the supplied listener to the
downloadingPeer
This commit is contained in:
parent
12bfa5f5ee
commit
d1c3be126d
@ -1004,6 +1004,8 @@ public class PeerGroup extends AbstractExecutionThreadService implements Transac
|
||||
try {
|
||||
if (downloadPeer != null && this.downloadListener != null)
|
||||
downloadPeer.removeEventListener(this.downloadListener);
|
||||
if (downloadPeer != null && listener != null)
|
||||
downloadPeer.addEventListener(listener);
|
||||
this.downloadListener = listener;
|
||||
// TODO: be more nuanced about which peer to download from. We can also try
|
||||
// downloading from multiple peers and handle the case when a new peer comes along
|
||||
|
Loading…
x
Reference in New Issue
Block a user