Commit 038dce1e authored by Joris Guisson's avatar Joris Guisson
Browse files

Backport DHT fix from trunk

svn path=/branches/stable/extragear-kde4/network/ktorrent/; revision=984599
parent e84c499f
......@@ -2,6 +2,7 @@ Changes in 3.2.3:
- Make sure View gets focus back when you are finished editing the name of a torrent
- Fix bug causing sizes > 4GB not being displayed properly in plasma applet
- Fix bug in sleep suppression feature causing it to not work when torrents get started at startup (195991)
- Also announce to DHT node when we get back a GetPeers with nodes (194366)
Changes in 3.2.2 :
- Fix crash when changing speed limits using system tray menu (188447)
......
......@@ -85,15 +85,15 @@ namespace dht
returned_items.append(*i);
}
// add the peer who responded to the answered list, so we can do an announce
KBucketEntry e(rsp->getOrigin(),rsp->getID());
if (!answered.contains(KBucketEntryAndToken(e,gpr->getToken())) && !answered_visited.contains(e))
{
answered.append(KBucketEntryAndToken(e,gpr->getToken()));
}
emitDataReady();
}
// add the peer who responded to the answered list, so we can do an announce
KBucketEntry e(rsp->getOrigin(),rsp->getID());
if (!answered.contains(KBucketEntryAndToken(e,gpr->getToken())) && !answered_visited.contains(e))
{
answered.append(KBucketEntryAndToken(e,gpr->getToken()));
}
}
void AnnounceTask::callTimeout(RPCCall* )
......@@ -114,6 +114,7 @@ namespace dht
{
AnnounceReq* anr = new AnnounceReq(node->getOurID(),info_hash,port,e.getToken());
anr->setOrigin(e.getAddress());
//Out(SYS_DHT|LOG_DEBUG) << "DHT: Announcing to " << e.getAddress().toString() << endl;
rpcCall(anr);
answered_visited.append(e);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment