mirror of https://github.com/aria2/aria2
2008-09-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Made a socket of incoming peer non-blocking. * src/PeerListenCommand.ccpull/1/head
parent
4f280af10b
commit
c1dd780b95
|
@ -1,3 +1,8 @@
|
||||||
|
2008-09-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||||
|
|
||||||
|
Made a socket of incoming peer non-blocking.
|
||||||
|
* src/PeerListenCommand.cc
|
||||||
|
|
||||||
2008-09-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
2008-09-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||||
|
|
||||||
Fixed the bug that aria2 may send duplicate data to BitTorrent peer if
|
Fixed the bug that aria2 may send duplicate data to BitTorrent peer if
|
||||||
|
|
|
@ -97,9 +97,7 @@ bool PeerListenCommand::execute() {
|
||||||
std::pair<std::string, uint16_t> peerInfo;
|
std::pair<std::string, uint16_t> peerInfo;
|
||||||
peerSocket->getPeerInfo(peerInfo);
|
peerSocket->getPeerInfo(peerInfo);
|
||||||
|
|
||||||
// Since peerSocket may be in non-blocking mode, make it blocking mode
|
peerSocket->setNonBlockingMode();
|
||||||
// here.
|
|
||||||
//peerSocket->setBlockingMode();
|
|
||||||
|
|
||||||
PeerHandle peer(new Peer(peerInfo.first, peerInfo.second, true));
|
PeerHandle peer(new Peer(peerInfo.first, peerInfo.second, true));
|
||||||
int32_t cuid = CUIDCounterSingletonHolder::instance()->newID();
|
int32_t cuid = CUIDCounterSingletonHolder::instance()->newID();
|
||||||
|
|
Loading…
Reference in New Issue