diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2010-03-21 07:05:49 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2010-03-21 07:05:49 +0000 |
| commit | de8fef01f3119719441b36c758fd5bd924bcf607 (patch) | |
| tree | 61be92e32b982948d39421a4a58acfbb21e5e50c /src/InitiatorMSEHandshakeCommand.cc | |
| parent | 322a0d1ad7e0ab0eaae6335baf91f5423b92c7f4 (diff) | |
2010-03-21 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Defined cuid_t as int64_t. Removed texts containing "CUID#%D" from
translatable texts because it is used in log and debugging
purpose.
Diffstat (limited to 'src/InitiatorMSEHandshakeCommand.cc')
| -rw-r--r-- | src/InitiatorMSEHandshakeCommand.cc | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/InitiatorMSEHandshakeCommand.cc b/src/InitiatorMSEHandshakeCommand.cc index de4c20c0..2bd27e9c 100644 --- a/src/InitiatorMSEHandshakeCommand.cc +++ b/src/InitiatorMSEHandshakeCommand.cc @@ -53,6 +53,7 @@ #include "RequestGroup.h" #include "DownloadContext.h" #include "bittorrent_helper.h" +#include "util.h" namespace aria2 { @@ -169,7 +170,11 @@ bool InitiatorMSEHandshakeCommand::executeInternal() { bool InitiatorMSEHandshakeCommand::prepareForNextPeer(time_t wait) { if(getOption()->getAsBool(PREF_BT_REQUIRE_CRYPTO)) { - logger->info("CUID#%d - Establishing connection using legacy BitTorrent handshake is disabled by preference.", cuid); + if(logger->info()) { + logger->info("CUID#%s - Establishing connection using legacy BitTorrent" + " handshake is disabled by preference.", + util::itos(cuid).c_str()); + } if(_peerStorage->isPeerAvailable() && _btRuntime->lessThanEqMinPeers()) { SharedHandle<Peer> peer = _peerStorage->getUnusedPeer(); peer->usedBy(e->newCUID()); @@ -183,7 +188,10 @@ bool InitiatorMSEHandshakeCommand::prepareForNextPeer(time_t wait) return true; } else { // try legacy BitTorrent handshake - logger->info("CUID#%d - Retry using legacy BitTorrent handshake.", cuid); + if(logger->info()) { + logger->info("CUID#%s - Retry using legacy BitTorrent handshake.", + util::itos(cuid).c_str()); + } PeerInitiateConnectionCommand* command = new PeerInitiateConnectionCommand(cuid, _requestGroup, peer, e, _btRuntime, false); |
