Now download line is printed nicely with no garbage at the end
of
line. I use ioctl to get the columns of terminal.
If stdout is redirected to another device, instead of carriage
return,
end of line '\n' character is used. This is feature
request#1909659
* src/ConsoleStatCalc.cc (calculateStat)
Fixed high memory footprint when DHT is enabled.
This is not a memory leak, but DHTReplaceNodeTask is more frequently
queued than it is processed and the queue is getting longer. As a
consequence, momory usage is increased.
As for a fix, instead of issuing DHTReplaceNodeTask, I've implemented
replacement cache in DHTBucket which is described in Kademlia paper.
* src/DHTRoutingTable.cc (addNode): Removed the issuing of
DHTReplaceNodeTask.
* src/DHTBucket.{h, cc}
(cacheNode): New function.
(getCachedNodes): New function.
(dropNode): Push back cached node to _nodes.
* test/DHTBucketTest.cc
(testCacheNode): New test
(testDropNode): New test
* src/Util.{h, cc}
(parseUInt): New function.
(alphaToNum): Now returns unsigned int and 0 when overflow
detected.
The actual range is uint32_t.
* test/UtilTest.cc
* src/ParameterizedStringParser.cc:
Use Util::parseUInt() for loop variables.
* test/ParameterizedStringParserTest.cc
* src/PStringNumLoop.h: Make _startValue and _endValue unsigned
int.
Type clarification
* src/PeerSessionResource.{h, cc}
* src/DefaultPieceStorage.{h, cc}
* src/Peer.{h, cc}
* test/PeerSessionResourceTest.cc
Use div function
* src/BtPieceMessage.cc (erasePieceOnDisk)
Fixed compilation error with --disable-nls
It seems that defining gettext(Msgid) to ((const char *)
(Msgid))
in gettext.h causes the problem.
* src/common.h
Changed inactive connection timeout to 120.
To accept more mulually interested peers, disconnect peer when
there
is no interest between us after certain time passed.
* src/DefaultBtInteractive.cc (checkActiveInteraction)
Fixed the bug that aria2 only uses first dns server in
resolv.conf
when compiled with async DNS support.
* src/DownloadEngine.cc
* src/option_processing.cc: Lengthened DNS timeout to 30. I
think old
value '10' will be a little bit short when some DNS servers are
offline and several DNS servers are tried. It should be
configured
by command-line option.
Updated Makfefile.am to make 'make dist' work.
Now packaged filename is aria2c-VERSION.tar.bz2.
Added README, README.html, and aria2c.1.html to dist_doc_DATA.
Added LICENSE.OpenSSL to dist_noinst_DATA.
Large file support is now configured by configure script.
* configure.ac
Removed unsused source files
* src/
* test/
Removed PeerDecl.h and BtContextDecl.h. typedefs are removed to
Peer.h and BtContext.h respectively.
* src/Peer.h
* src/BtContext.h
Updated translations.
Added Polish, Thai, Indonesian, Norwegian Nynorsk, Hungarian
translations. Great thanks to all translators!;)
* po/*.{po, gmo}
Create MessageDigestHelper::staticSHA1DigestInit() which uses
statically declared sha1 MessageDigestContext.
* src/BtPieceMessage.cc: Use staticSHA1DigestInit() to avoid
initialization of short-lived MessageDigestContext.
* src/MessageDigestHelper.{h, cc}
* src/main.cc
Now DownloadCommand has a reference to MessageDigestContext to avoid
the initialization of MessageDigestContext every time in validating
chunk checksum.
* src/DownloadCommand.{h, cc}
Add a file descriptor which connected to fast peer(latency<1500)
to
select(). This change reduced CPU load.
* src/PeerInteractionCommand.cc
* src/DefaultBtInteractive.{h, cc}
* src/BtInteractive.h
Fixed possible busy loop if first 20 bytes are not received for
a few
minutes.
* src/MSEHandshake.{h, cc} (identifyHandshakeType)
* src/ReceiverMSEHandshakeCommand.cc
Fixed the bug that HAVE message is not sent for a piece they are
downloaded fom http/ftp server before any BitTorrent handshake
is done
with peers.
* src/DefaultBtInteractive.cc
Updated README. Added html version of README and man page.
* README
* README.html
* readme2html: Shell script to generate README.html from README
using
asciidoc.
* doc/aria2c.1.html
* doc/makeman: Added the line to generate aria2c.1.html
Fixed the bug that DH key exchange sometimes fails due to bad
handling
of the number of bytes required for storing public key and
shared
secret.
* src/LibgcryptDHKeyExchange.h
* src/LibsslDHKeyExchange.h: Also added function name to
handleError.
* src/MSEHandshake.cc
* test/DHKeyExchangeTest.cc
Fixed the bug that prevents aria2 from stopping other than by
pressing
Ctrl-C in BitTorrent download. It is reproducible using
--seed-time
option. aria2 doesn't stop even after --seed-time is satisfied
and
continues to output blank lines in the console.
* src/ReceiverMSEHandshakeCommand.cc
* src/PeerReceiveHandshakeCommand.cc
* src/PeerListenCommand.cc