2006-04-28 15:55:11 +00:00
|
|
|
2006-04-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add --select-file command-line option:
|
|
|
|
|
|
|
|
* src/Util.cc
|
|
|
|
(unfoldRange): New function.
|
|
|
|
(getNum): New function.
|
|
|
|
(unfoldSubRange): New function
|
|
|
|
* src/main.cc
|
|
|
|
(showUsage): Added help message.
|
|
|
|
(main): Added --select-file command-line option.
|
|
|
|
|
|
|
|
2006-04-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To deploy upload rate based choking algorithm:
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand.cc
|
|
|
|
(PeerInteractionCommand): Add peer to TorrentMan::activePeers to track
|
|
|
|
peer currently used.
|
|
|
|
(decideChoking): Deleted the choke/unchoke decision algorithm when
|
|
|
|
download completes. Simplified.
|
|
|
|
(receiveMessage): Updated.
|
|
|
|
* src/TorrentMan.h
|
|
|
|
(activePeers): New variable.
|
|
|
|
(addActivePeer): New function.
|
|
|
|
(getActivePeers): New function.
|
|
|
|
(deleteActivePeer): New function.
|
|
|
|
* src/TorrentMan.cc
|
|
|
|
(addPeer): deleteOldErrorPeers is moved to the begining of the function
|
|
|
|
* src/PeerAbstractCommand.cc
|
|
|
|
(onAbort): Use peer->resetStatus().
|
|
|
|
* src/main.cc
|
|
|
|
(PeerChokeCommand.h): Included.
|
|
|
|
(main): Added the instance of ChokingCommand to the command queue.
|
|
|
|
* src/Peer.h
|
|
|
|
(amChoking): Renamed from amChocking
|
|
|
|
(chokingRequired): New variable.
|
|
|
|
(optUnchoking): New variable.
|
|
|
|
(deltaUpload): New variable.
|
|
|
|
(deltaDownload): New variable.
|
|
|
|
(addDeltaUpload): New function.
|
|
|
|
(resetDeltaUpload): New function.
|
|
|
|
(addDeltaDownload): New function.
|
|
|
|
(resetDeltaDownload): New function.
|
|
|
|
(addPeerUpload): Added a call to addDeltaUpload.
|
|
|
|
(addPeerDownload): Added a call to addDeltaDownload.
|
|
|
|
* src/Peer.cc
|
|
|
|
(shouldBeChoking): Renamed from shouldChoke.
|
|
|
|
(resetStatus): New function.
|
|
|
|
* src/PeerChokeCommand.h: New class.
|
|
|
|
* src/PeerChokeCommand.cc: New class.
|
|
|
|
|
|
|
|
To add lazy upload speed limiter:
|
|
|
|
|
|
|
|
* src/TorrentConsoleDownloadEngine.h: Moved the variables for
|
|
|
|
statistics calculation to TorrentDownloadEngine.
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc
|
|
|
|
(sendStatistics): Renamed from printStatistics.
|
|
|
|
(initStatistics): Removed. Moved to TorrentDownloadEngine.
|
|
|
|
(calculateSpeed): Removed. Moved to TorrentDownloadEngine.
|
|
|
|
(calculateStatistics): Removed. Moved to TorrentDownloadEngine.
|
|
|
|
* src/TorrentDownloadEngine.h: Added the variables for statistics
|
|
|
|
calculation.
|
|
|
|
(sendStatistics): New function as pure virtual function.
|
|
|
|
(getUploadSpeed): New function.
|
|
|
|
* src/TorrentDownloadEngine.cc
|
|
|
|
(initStatistics): New function.
|
|
|
|
(calculateSpeed): New function.
|
|
|
|
(calculateStatistics): New function.
|
|
|
|
* src/SendMessageQueue.h
|
|
|
|
(uploadLength): New variable.
|
|
|
|
(send): Added an argument.
|
|
|
|
(setUploadLimit): New function.
|
|
|
|
(getUploadLimit): New function.
|
|
|
|
* src/SendMessageQueue.cc
|
|
|
|
(send): Added upload speed limiter.
|
|
|
|
* src/prefs.h
|
|
|
|
(PREF_UPLOAD_LIMIT): New definition.
|
|
|
|
* src/PeerInteractionCommand.cc
|
|
|
|
(PeerInteractionCommand): Set upload speed limit to sendMessageQueue.
|
|
|
|
* src/main.cc
|
|
|
|
(main): Added --upload-limit option
|
|
|
|
|
|
|
|
For bug fixes:
|
|
|
|
|
|
|
|
* src/main.cc
|
|
|
|
(showUsage): Corrected --listen-port help
|
|
|
|
|
|
|
|
Other changes:
|
|
|
|
|
|
|
|
* src/TorrentMan.cc
|
|
|
|
(getPeer): Return nullPeer if connection is grather than
|
|
|
|
MAX_PEER_UPDATE(15) in order to leave space for incoming peers.
|
|
|
|
|
2006-04-20 15:58:05 +00:00
|
|
|
2006-04-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add some useful information to the exception message:
|
|
|
|
|
|
|
|
* src/SocketCore.cc : Updated messages.
|
|
|
|
* src/SegmentMan.cc :
|
|
|
|
* src/TorrentMan.cc : Updated messages.
|
|
|
|
* src/MultiDiskWriter.cc : Updated messages.
|
|
|
|
* src/Util.cc : Updated messages.
|
|
|
|
* src/AbstractDiskWriter.cc : Updated messages.
|
|
|
|
* src/PreAllocationDiskWriter.cc : Updated messages.
|
|
|
|
* src/message.cc : Added new messages. Updated some messages.
|
|
|
|
|
|
|
|
* src/TrackerWatcherCommand.h (MIN_PEERS): New definition.
|
|
|
|
* src/TrackerWatcherCommand.cc (execute): Use MIN_PEERS.
|
|
|
|
Updated threshold from 30 to 15.
|
|
|
|
|
|
|
|
* src/AbstractDiskWriter.h (filename): New variable.
|
|
|
|
* src/AbstractDiskWriter.cc (openExistingFile): Assigned filename.
|
|
|
|
(createFile): Assigned filename.
|
|
|
|
|
|
|
|
* src/main.cc: Updated the help message for http-auth-scheme.
|
|
|
|
|
2006-04-21 13:18:42 +00:00
|
|
|
* Release 0.4.0
|
|
|
|
|
2006-04-19 17:23:58 +00:00
|
|
|
2006-04-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add TrackerUpdateCommand with which replaces
|
|
|
|
CompactTrackerResponseProcessor:
|
|
|
|
|
|
|
|
* src/TrackerWatcherCommand.h (req): Removed.
|
|
|
|
* src/TrackerWatcherCommand.cc (execute): Send a request to tracker
|
|
|
|
if the number of peer connections are less than 30.
|
|
|
|
* src/ByteArrayDiskWriter.h (readData): Implemented.
|
|
|
|
* src/SegmentMan.h (diskWriter): New function.
|
|
|
|
* src/SegmentMan.cc (init): Added a call to diskWriter->closeFile()
|
|
|
|
* src/main.cc : Removed #include "CompactTrackerResponseProcessor.h"
|
|
|
|
(main): Use TrackerUpdateCommand.
|
|
|
|
* src/TorrentMan.h (CompactTrackerResponseProcessor): Removed.
|
|
|
|
(req): New variable.
|
|
|
|
(setTrackerResponseProcessor): Removed.
|
|
|
|
(getTrackerResponseProcessor): Removed.
|
|
|
|
(processTrackerResponse): Removed.
|
|
|
|
* src/DownloadEngine.h (diskWriter): Removed.
|
|
|
|
* src/TorrentDownloadEngine.cc (afterEachIteration): Removed a call
|
|
|
|
to torrentMan->processTrackerResponse().
|
|
|
|
|
|
|
|
To add Util::expandBuffer:
|
|
|
|
|
|
|
|
* src/ByteArrayDiskWriter.h (expandBuffer): Removed.
|
|
|
|
* src/ByteArrayDiskWriter.cc (writeData): Use Util::expandBuffer().
|
|
|
|
* src/Util.h (expandBuffer): New function.
|
|
|
|
|
|
|
|
To fix the bug that causes segmentation fault when "-l ." is specified
|
|
|
|
in command-line option:
|
|
|
|
|
|
|
|
* src/SimpleLogger.h (SimpleLogger): Removed "filename" argument.
|
|
|
|
(openFile): New function.
|
|
|
|
(closeFile): New function.
|
|
|
|
* src/SimpleLogger.cc (SimpleLogger): Removed fopen.
|
|
|
|
(~SimpleLogger): Call closeFile();
|
|
|
|
* src/LogFactory.cc (getInstance): Added a call to slogger->openFile().
|
|
|
|
* src/main.cc (main): Added a check to see logger is configured
|
|
|
|
properly.
|
|
|
|
|
|
|
|
To enable HTTP authentication without specifying "--http-auth-scheme"
|
|
|
|
|
|
|
|
* src/prefs.h (PREF_HTTP_AUTH_ENABLED): New definition.
|
|
|
|
* src/HttpConnection.cc (createRequest): Send Authorization header
|
|
|
|
if PREF_HTTP_AUTH_ENABLED == V_TRUE.
|
|
|
|
* src/main.cc (main): Preset PREF_HTTP_AUTH_SCHEME to V_TRUE
|
|
|
|
If "--http-user" is specified, set PREF_HTTP_AUTH_ENABLED to V_TRUE
|
|
|
|
|
|
|
|
* src/Peer.cc (shouldChoke): Updated algorithm.
|
|
|
|
|
|
|
|
* src/message.h (EX_AUTH_FAILED): New definition.
|
|
|
|
(EX_FILE_OPEN): New definition.
|
|
|
|
* src/HttpResponseCommand.cc (checkResponse): Throw DlAbortEx
|
|
|
|
if status == 401.
|
|
|
|
(handleDefaultEncoding): Added a call to diskWriter->initAndOpenFile()
|
|
|
|
if req->isTorrent == true.
|
|
|
|
|
|
|
|
* src/main.cc (handler): Removed the check to see e->diskWriter != NULL
|
|
|
|
(torrentHandler): Removed the check to see diskAdaptor != NULL.
|
|
|
|
|
|
|
|
* src/AbstractDiskWriter.cc (openExistingFile): Updated messsage.
|
|
|
|
(createFile): Updated message.
|
|
|
|
|
2006-04-18 17:06:17 +00:00
|
|
|
2006-04-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add a readout of estimated remaining time to normal HTTP/FTP
|
|
|
|
downloads:
|
|
|
|
|
|
|
|
* src/ConsoleDownloadEngine.h (startup): New variable.
|
|
|
|
(startupLength): New variable.
|
|
|
|
(isStartupLengthSet): New variable.
|
|
|
|
(avgSpeed): New variable.
|
|
|
|
(eta): New variable.
|
|
|
|
* src/ConsoleDownloadEngine.cc (sendStatistics): Added a readout of
|
|
|
|
estimated remaining time.
|
|
|
|
(initStatistics): Initialized newly added variables.
|
|
|
|
(calculateStatistics): Calculate average speed and estimated remaining
|
|
|
|
time.
|
|
|
|
|
|
|
|
To decouple TorrentDownloadEngine from HttpResponseCommand:
|
|
|
|
|
|
|
|
* src/TrackerDownloadCommand.h: Removed.
|
|
|
|
* src/TrackerDownloadCommand.cc: Removed.
|
|
|
|
* src/TrackerInitCommand.h: Removed.
|
|
|
|
* src/TrackerInitCommand.cc: Removed.
|
|
|
|
* src/TrackerUpdateCommand.h: Removed.
|
|
|
|
* src/TrackerUpdateCommand.cc: Removed.
|
|
|
|
* src/TrackerWatcherCommand.cc (execute): The construction of request
|
|
|
|
url written in TrackerInitCommand was moved here. Do not create
|
|
|
|
tracker request command if torretnMan->trackers != 0.
|
|
|
|
* src/CompactTrackerResponseProcessor.h: New class.
|
|
|
|
* src/CompactTrackerResponseProcessor.cc: New class.
|
|
|
|
* src/message.h (MSG_TRACKER_WARNING_MESSAGE): Updated.
|
|
|
|
* src/HttpResponseCommand.cc (createHttpDownloadCommand):
|
|
|
|
Decoupled TorrentDownloadEngine from this.
|
|
|
|
* src/SegmentMan.h (init): New function.
|
|
|
|
* src/SegmentMan.cc (init): New function.
|
|
|
|
* src/TorrentMan.h (responseProcessor): New variable.
|
|
|
|
(trackers): New variable.
|
|
|
|
(setTrackerResponseProcessor): New function.
|
|
|
|
(getTrackerResponseProcessor): New function.
|
|
|
|
(processTrackerResponse): New function.
|
|
|
|
* src/TorrentMan.cc (Constructor): Initialized new variable trackers.
|
|
|
|
(processTrackerResponse): New function.
|
|
|
|
* src/main.cc (main): Use ByteArrayDiskWriter and
|
|
|
|
CompactTrackerResponseProcessor.
|
|
|
|
* src/TorrentDownloadEngine.cc (afterEachIteration): Call torrentMan->
|
|
|
|
processTrackerResponse().
|
|
|
|
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc (printStatistics): Updated a
|
|
|
|
readout.
|
|
|
|
|
|
|
|
* src/TorrentDownloadEngine.cc (afterEachIteration): Added log message
|
|
|
|
which indicates download has completed.
|
|
|
|
|
|
|
|
* src/AbstractDiskWriter.cc (Destructor): fd >= 0, not fd >0
|
|
|
|
(closeFile): fd >= 0, not fd > 0
|
|
|
|
|
|
|
|
* src/main.cc (main): Added short cut for show-files.
|
|
|
|
Added short cut for torrent-file.
|
|
|
|
Added new command-line option listen-port.
|
|
|
|
Updated i18n messages.
|
|
|
|
|
2006-04-17 16:17:20 +00:00
|
|
|
2006-04-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add LogFactory which creates singleton logger:
|
|
|
|
|
|
|
|
* src/LogFactory.h: New class.
|
|
|
|
* src/LogFactory.cc: New class.
|
|
|
|
* src/Command.h (logger): New variable.
|
|
|
|
(Constructor): Use LogFactory.
|
|
|
|
* src/AbstractCommand.cc: Use Command::logger
|
|
|
|
* src/PeerConnection.cc (Constructor): Deleted the argument logger.
|
|
|
|
Use LogFactory.
|
|
|
|
* src/SegmentSplitter.h : Made logger protected.
|
|
|
|
* src/SegmentSplitter.cc (Constructor): Use LogFactory.
|
|
|
|
* src/SegmentMan.cc (Constructor): Use LogFactory.
|
|
|
|
* src/DownloadEngine.h : Made logger protected.
|
|
|
|
* src/DownloadEngine.cc (Constructor): Use LogFactory.
|
|
|
|
* src/PeerInteractionCommand.cc : Use Command::logger.
|
|
|
|
* src/HttpResponseCommand.cc : Use Command::logger.
|
|
|
|
* src/SegmentMan.h : Made logger private.
|
|
|
|
* src/TorrentMan.h : Made logger private.
|
|
|
|
* src/TorrentMan.cc : Use LogFactory.
|
|
|
|
* src/FtpNegotiateCommand.cc : Use Command::logger.
|
|
|
|
* src/HttpConnection.h (Constructor): Deleted the argument logger.
|
|
|
|
* src/HttpConnection.cc (Constructor): Deleted the argument logger.
|
|
|
|
Use LogFactory.
|
|
|
|
* src/FtpConnection.h (Constructor): Deleted the argument logger.
|
|
|
|
* src/FtpConnection.cc (Constructor): Deleted the argument logger.
|
|
|
|
Use LogFactory.
|
|
|
|
* src/DownloadCommand.cc : Use Command::logger.
|
|
|
|
* src/PeerAbstractCommand.cc : Use Command::logger.
|
|
|
|
* src/PeerListenCommand.cc : Use Command::logger.
|
|
|
|
* src/PeerInitiateConnectionCommand.cc : Use Command::logger.
|
|
|
|
* src/HttpInitiateConnectionCommand.cc : Use Command::logger.
|
|
|
|
* src/FtpInitiateConnectionCommand.cc : Use Command::logger.
|
|
|
|
* src/TrackerWatcherCommand.cc : Use Command::logger.
|
|
|
|
* src/TrackerUpdateCommand.cc : Use Command::logger.
|
|
|
|
* src/TrackerDownloadCommand.cc : Use Command::logger.
|
|
|
|
* src/RequestSlotMan.cc (Constructor): Deleted the argument logger.
|
|
|
|
Use LogFactory.
|
|
|
|
* src/SendMessageQueue.h (Constructor): Deleted the argument logger.
|
|
|
|
* src/SendMessageQueue.cc (Constructor): Deleted the argument logger.
|
|
|
|
Use LogFactory.
|
|
|
|
* src/main.cc (main): Use LogFactory.
|
|
|
|
* src/DiskAdaptor.h (logger): New variable.
|
|
|
|
* src/DiskAdaptor.cc (Constructor): Use LogFactory.
|
|
|
|
* src/CopyDiskAdaptor.cc (fixFilename): Added a log message.
|
|
|
|
|
2006-04-17 14:15:36 +00:00
|
|
|
2006-04-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* src/TrackerInitCommand.cc (TrackerInitCommand): Added a "key"
|
|
|
|
parameter to a tracker request.
|
|
|
|
|
|
|
|
* src/TorrentMan.cc (readFileEntryFromMetaInfoFile): Bug fix.
|
|
|
|
|
|
|
|
* src/TrackerWatcherCommand.cc (execute): Call req->resetTryCount().
|
|
|
|
|
|
|
|
* src/main.cc (setSignalHander): New function.
|
|
|
|
(main): Added a handler for SIGTERM.
|
|
|
|
(handler): Updated message.
|
|
|
|
(torrentHandler): Updated message.
|
|
|
|
|
|
|
|
|
2006-04-16 14:38:19 +00:00
|
|
|
2006-04-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc
|
|
|
|
(onPartialDownloadingCompletes): Renamed as
|
|
|
|
onSelectiveDownloadingCompletes.
|
|
|
|
(onSelectiveDownloadingCompletes): Updated message.
|
|
|
|
|
|
|
|
To add DiskAdaptor which abstract DiskWriter family:
|
|
|
|
|
|
|
|
* src/PeerConnection.cc: Use diskAdaptor instead of diskWriter.
|
|
|
|
* src/PeerInteractionCommand.cc: Use diskAdaptor instead of diskWriter.
|
|
|
|
* src/BitfieldMan.cc (isAllBitSet): bug fix.
|
|
|
|
* src/TorrentMan.cc : Included CopyDiskAdaptor.h, DirectDiskAdaptor.h,
|
|
|
|
MultiDiskAdaptor.h.
|
|
|
|
(readFileEntry): Changed its arguments.
|
|
|
|
(setup): setupDiskWriter is merged into this function.
|
|
|
|
(setupDiskWriter): Removed.
|
|
|
|
(setFileFilter): New function.
|
|
|
|
(readFileEntryFromMetaInfoFile): Updated according to the changes
|
|
|
|
made in readFileEntry.
|
|
|
|
(getFilePath): Removed.
|
|
|
|
(getTempFilePath): Removed.
|
|
|
|
(getSegmentFilePath): Updated due to the removal of getFilePath.
|
|
|
|
(fixFilename): Removed.
|
|
|
|
(copySingleFile): Removed.
|
|
|
|
(splitMultiFile): Removed.
|
|
|
|
(deleteTempFile): Removed.
|
|
|
|
(setFileEntriesToDownload): Removed.
|
|
|
|
(isPartialDownloadingMode): Renamed as isSelectiveDownloadingMode.
|
|
|
|
(isSelectiveDownloadingMode): New function.
|
|
|
|
(setAllMultiFileRequestedState): Removed.
|
|
|
|
(finishPartialDownloadingMode): Renamed as
|
|
|
|
finishSelectiveDownloadingMode.
|
|
|
|
(finishSelectiveDownloadingMode): New function.
|
|
|
|
(getPartialTotalLength): Renamed as getSelectedTotalLength.
|
|
|
|
(getSelectedTotalLength): New function.
|
|
|
|
(onDownloadComplete): Use diskAdaptor.
|
|
|
|
* src/MultiDiskWriter.cc (Constructor): Added the argument pieceLength
|
|
|
|
(Range): Removed.
|
|
|
|
(setMultiFileEntries): Renamed as setFileEntries.
|
|
|
|
(setFileEntries): New function.
|
|
|
|
* src/MultiDiskWriter.h [DiskWriterEntry](enabled): Removed.
|
|
|
|
(pieceLength): New variable.
|
|
|
|
* src/main.cc (printDownloadCompeleteMessage): New function.
|
|
|
|
(torrentHandler): Use diskAdaptor instead of diskWriter.
|
|
|
|
(main): Renamed torrent-show-files to show-files.
|
|
|
|
Rewritten file contents listing.
|
|
|
|
* src/TorrentMan.h (FileEntry): Removed.
|
|
|
|
(multiFileTopDir): Removed.
|
|
|
|
(multiFileEntries): Removed.
|
|
|
|
(diskWriter): Removed.
|
|
|
|
(diskAdaptor): New variable.
|
|
|
|
* src/DefaultDiskWriter.h (totalLength): New variable.
|
|
|
|
* src/DefaultDiskWriter.cc (initAndOpenFile): Added ftruncate.
|
|
|
|
* src/TorrentDownloadEngine.cc (onEndOfRun): Use diskAdaptor instead of
|
|
|
|
diskWriter.
|
|
|
|
* src/TorrentConsoleDownloadEngine.h
|
|
|
|
(partialDownloadLengthDiff): Renamed as selectedDownloadLengthDiff.
|
|
|
|
(partialTotalLength): Renamed as selectedTotalLength.
|
|
|
|
* src/AbstractDiskWriter.cc (openFile): If file exists, call
|
|
|
|
openExistingFile, otherwise call initAndOpenFile.
|
|
|
|
(closeFile): fd > 0, not fd != 0.
|
2006-04-16 14:42:26 +00:00
|
|
|
* src/DirectDiskAdaptor.h: New class.
|
|
|
|
* src/DirectDiskAdaptor.cc: New class.
|
|
|
|
* src/MultiDiskAdaptor.h: New class.
|
|
|
|
* src/MultiDiskAdaptor.cc: New class.
|
|
|
|
* src/CopyDiskAdaptor.h: New class.
|
|
|
|
* src/CopyDiskAdaptor.cc: New class.
|
|
|
|
* src/DiskAdaptor.h: New class.
|
|
|
|
* src/DiskAdaptor.cc: New class.
|
2006-04-16 14:38:19 +00:00
|
|
|
|
|
|
|
* src/prefs.h (PREF_TORRENT_SHOW_FILES): Renamed as PREF_SHOW_FILES
|
|
|
|
(PREF_SHOW_FILES): New definition.
|
|
|
|
|
2006-04-12 13:55:43 +00:00
|
|
|
2006-04-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To add the ability to download multi torrent into respective files
|
|
|
|
directly:
|
|
|
|
|
|
|
|
* src/DiskWriter.h (openFile): New function.
|
|
|
|
(seek): Removed.
|
|
|
|
* src/MultiDiskWriter.h: New class.
|
|
|
|
* src/MultiDiskWriter.cc: New class.
|
|
|
|
* src/AbstractDiskWriter.h (seek): Changed its scope from public to
|
|
|
|
protected.
|
|
|
|
(openFile): New function.
|
|
|
|
* src/AbstractDiskWriter.cc (openFile): New function.
|
|
|
|
* src/prefs.h (V_FALSE): New definition.
|
|
|
|
(PREF_DIRECT_FILE_MAPPING): New definition.
|
|
|
|
* src/TorrentMan.h (setupDiskWriter): New function.
|
|
|
|
(setAllMultiFileRequestedState): New function.
|
|
|
|
(onDownloadComplete): New function.
|
|
|
|
* src/TorrentMan.cc : Included MultiDiskWriter.h
|
|
|
|
(setupDiskWriter): New function.
|
|
|
|
(getFilePath): Updated.
|
|
|
|
(getTempFilePath): Updated.
|
|
|
|
(getSegmentFilePath): Updated.
|
|
|
|
(fixFilename): Updated.
|
|
|
|
(deleteTempFile): Updated.
|
|
|
|
(setAllMultiFileRequestedState): New function.
|
|
|
|
(setFileEntriesToDownload): Use setAllMultiFileRequestedState().
|
|
|
|
(finishPartialDownloadingMode): Reset requested flags.
|
|
|
|
(onDownloadComplete): New function.
|
|
|
|
* src/main.cc: Added --direct-file-mapping option.
|
|
|
|
Use TorretMan::setupDiskWriter().
|
|
|
|
* src/TorrentDownloadEngine.cc (afterEachIteration): Use TorrentMan::
|
|
|
|
onDownloadComplete().
|
|
|
|
|
|
|
|
|
|
|
|
To fix ETA bug:
|
|
|
|
|
|
|
|
* src/Util.h (difftvsec): New function.
|
|
|
|
* src/Util.cc (difftvsec): New function.
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc (calculateSpeed): Use int for the
|
|
|
|
type of "elapsed" instead of long long int.
|
|
|
|
(calculateStatistics): Use Util::difftvsec instead of Util::difftv.
|
|
|
|
The updates of statistics takes place every 1 seconds.
|
|
|
|
* src/TorrentConsoleDownloadEngine.h (lastElapsed): Changed its type.
|
|
|
|
(calculateSpeed): Changed its argument signature.
|
|
|
|
|
|
|
|
* src/PeerMessage.cc (toString): Fixed message.
|
|
|
|
|
2006-04-06 12:52:16 +00:00
|
|
|
2006-04-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To print ETA:
|
|
|
|
|
|
|
|
* src/TorrentDownloadEngine.cc (afterEachIteration): Added download
|
|
|
|
completion handling when dealing with
|
|
|
|
TorrentMan::isPartialDownloadingMode() == true.
|
|
|
|
* src/TorrentDownloadEngine.h (onPartialDownloadingCompletes):
|
|
|
|
New function.
|
|
|
|
* src/TorrentConsoleDownloadEngine.h (startup): New variable.
|
|
|
|
(sessionDownloadLength): New variable.
|
|
|
|
(avgSpeed): New variable.
|
|
|
|
(eta): New variable.
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc (initStatistics): Initialized
|
|
|
|
new variables: eta, avgSpeed, startup.
|
|
|
|
(calculateSpeed): Calculate average speed and ETA.
|
|
|
|
(printStatistics): Added ETA.
|
|
|
|
|
|
|
|
* src/Util.h (secfmt): New function.
|
|
|
|
* src/Util.cc (secfmt): New function.
|
|
|
|
|
|
|
|
2006-04-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
To detect "keep alive" flooding:
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand.h (keepAliveCount): New variable
|
|
|
|
* src/PeerInteractionCommand.cc (Constructor): Initialized new
|
|
|
|
variable: keepAliveCount.
|
|
|
|
(detectMessageFlooding): Added "keep alive" flooding detection.
|
|
|
|
(receiveMessage): Increase keepAliveCount when "keep alive" message
|
|
|
|
received.
|
|
|
|
|
|
|
|
To add the ability to download only specified files in multi-file
|
|
|
|
torrent:
|
|
|
|
|
|
|
|
* src/BitfieldMan.h (filterBitfield): New variable.
|
|
|
|
(filterEnabled): New variable.
|
|
|
|
(setFilterBit): New function.
|
|
|
|
(enableFilter): New function.
|
|
|
|
(disableFilter): New function.
|
|
|
|
(isFilterEnabled): New function.
|
|
|
|
(getFilteredTotalLength): New function.
|
|
|
|
(getCompletedLength): New function.
|
|
|
|
* src/BitfieldMan.cc (Constructor): Initialized new variable:
|
|
|
|
filterBitfield, filterEnabled.
|
|
|
|
(CopyConstructor): Added filterBitfield and filterEnabled.
|
|
|
|
(operator==): Added filterBitfield and filterEnabled.
|
|
|
|
(Destructor): Added filterBitfield.
|
|
|
|
(getMissingIndex): Use filterBitfield.
|
|
|
|
(getMissingUnusedIndex): Use filterBitfield.
|
|
|
|
(getFirstMissingUnusedIndex): Use filterBitfield.
|
|
|
|
(getFirstMissingUnusedIndex): Use filterBitfield.
|
|
|
|
(getAllMissingIndexes): Use filterBitfield.
|
|
|
|
(countMissingBlock): Use filterBitfield.
|
|
|
|
(countBlock): Use filterBitfield.
|
|
|
|
(setBitInternal): Added new argument on.
|
|
|
|
(setUseBit): Use setBitInternal.
|
|
|
|
(unsetUseBit): Use setBitInternal.
|
|
|
|
(setBit): Use setBitInternal.
|
|
|
|
(unsetBit): Use setBitInternal.
|
|
|
|
(isAllBitSet): Use filterBitfield.
|
|
|
|
(setFilterBit): New function.
|
|
|
|
(addFilter): New function.
|
|
|
|
(enableFilter): New function.
|
|
|
|
(disableFilter): New function.
|
|
|
|
(clearFilter): New function.
|
|
|
|
(isFilterEnabled): New function.
|
|
|
|
(getFilteredTotalLength): New function.
|
|
|
|
(getCompletedLength): New function.
|
|
|
|
|
|
|
|
* src/TorrentMan.h [FileEntry](Constructor): Updated signature.
|
|
|
|
Initalized newly added variables.
|
|
|
|
[FileEntry](offset): New variable.
|
|
|
|
[FileEntry](extracted): New variable.
|
|
|
|
[FileEntry](requested): New variable.
|
|
|
|
(readFileEntry): New function.
|
|
|
|
(option): New variable.
|
|
|
|
(splitMultiFile): Removed const qualifier.
|
|
|
|
(fixFilename): Removed const qualifier.
|
|
|
|
(readFileEntryFromMetaInfoFile): New function.
|
|
|
|
(finishPartialDownloadingMode): New function.
|
|
|
|
(isPartialDownloadingMode): New function.
|
|
|
|
(setFileEntriesToDownload): New function.
|
|
|
|
(getCompletedLength): New function.
|
|
|
|
(getPartialTotalLength): New function.
|
|
|
|
* src/TorrentMan.cc (readFileEntry): New function.
|
|
|
|
(setup): Use readFileEntry. If no-preallocation option is specified,
|
|
|
|
use DefaultDiskWriter.
|
|
|
|
(readFileEntryFromMetaInfoFile): New function.
|
|
|
|
(fixFilename): Removed const qualifier.
|
|
|
|
(splitMultiFile): Removed const qualifier.
|
|
|
|
(setFileEntriesToDownload): New function.
|
|
|
|
(isPartialDownloadingMode): New function.
|
|
|
|
(finishPartialDownloadingMode): New function.
|
|
|
|
(getCompletedLength): New function.
|
|
|
|
(getPartialTotalLength): New function.
|
|
|
|
|
|
|
|
* src/TorrentConsoleDownloadEngine.h (partialDownloadLengthDiff):
|
|
|
|
New variable.
|
|
|
|
(partialTotalLength): New variable.
|
|
|
|
(downloadLength): New variable.
|
|
|
|
(totalLength): New variable.
|
|
|
|
* src/TorrentConsoleDownloadEngine.cc (onPartialDownloadingCompletes):
|
|
|
|
Added log.
|
|
|
|
(initStatistics): Initialized new variables: partialDownloadLengthDiff,
|
|
|
|
partialTotalLength, downloadLength, totalLength.
|
|
|
|
(calculate): Calculate downloadLength and totalLength.
|
|
|
|
|
|
|
|
* src/prefs.h :New definition PREF_NO_PREALLOCATION
|
|
|
|
|
|
|
|
* src/main.cc (addCommand): Changed argument signature.
|
|
|
|
(main): Added new variable: args. Added new option "torrent-show-files"
|
|
|
|
"no-preallocation". Usage is not updated yet.
|
|
|
|
|
|
|
|
2006-04-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* src/PeerMessage.cc (setBitfield): Fixed invalid memory de-allocation.
|
|
|
|
|
2006-04-01 14:39:45 +00:00
|
|
|
2006-04-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
Attempt to add the ability to listing file entries in a .torrent file.
|
|
|
|
This feature is not yet complete.
|
|
|
|
|
|
|
|
* src/prefs.h (PREF_TORRENT_SHOW_FILES): New definition
|
|
|
|
* src/TorrentMan.cc (getMultiFileEntries): New function.
|
|
|
|
(getName): New function.
|
|
|
|
* src/TorrentMan.h (getMultiFileEntries): New function.
|
|
|
|
(getName): New function.
|
|
|
|
* src/main.cc (main): Use above 2 funtion.
|
|
|
|
|
|
|
|
* Release 0.3.2
|
|
|
|
|
2006-03-31 13:58:22 +00:00
|
|
|
2006-03-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand.cc (checkInactiveConnection): New function
|
2006-04-01 14:39:45 +00:00
|
|
|
(detectMessageFlooding): Updated threshold value.
|
|
|
|
(checkLongTimePeerChoking): Updated timeout value.
|
2006-03-31 13:58:22 +00:00
|
|
|
(getNewPieceAndSendInterest): Added debug log.
|
2006-04-01 14:39:45 +00:00
|
|
|
* src/PeerInteractionCommand.h (checkInactiveConnection): New function
|
2006-03-31 13:58:22 +00:00
|
|
|
|
|
|
|
* src/TorrentMan.cc (deleteOldErrorPeers): Updated.
|
|
|
|
(getPeer): Updated.
|
|
|
|
* src/TorrentMan.h: Added MAX_PEER_ERROR.
|
|
|
|
|
|
|
|
* src/PeerAbstractCommand.cc (onAbort): Increment error counter.
|
|
|
|
|
|
|
|
* src/PeerListenCommand.cc (execute): Close connection if incoming peer
|
|
|
|
is localhost.
|
|
|
|
|
|
|
|
* src/main.cc (main): Updated PREF_PEER_CONNECTION_TIMEOUT to 60.
|
|
|
|
|
|
|
|
* src/PendingMessage.cc (processMessage): Not to send piece message
|
|
|
|
if peer is not interested in the pieces localhost has.
|
|
|
|
|
|
|
|
* src/Peer.cc (shouldChoke): Updated.
|
|
|
|
|
|
|
|
* src/SendMessageQueue.cc (cancelAllRequest): Fixed.
|
|
|
|
|
2006-03-31 16:15:23 +00:00
|
|
|
* src/Util.cc (isPowerOf): New function.
|
|
|
|
* src/Util.h (isPowerOf): New function.
|
|
|
|
* src/PeerMessageUtil.cc (checkLength): Added a check for length
|
|
|
|
whether or not it is power of 2.
|
|
|
|
|
Added new class SendMessageQueue that includes PendingMessages
and
RequestSlotMan.
* src/SendMessageQueue.h: New class.
* src/SendMessageQueue.cc: New class.
* src/PendingMessage.h: Added new member variable blockIndex and
its
accessors.
(createRequestMessage): Updated.
* src/PendingMessage.cc (createRequestMessage): Updated.
* src/PeerInteractionCommand.cc (executeInternal): Updated with
SendMessageQueue.
(checkLongTimePeerChoking): Updated with SendMessageQueue.
(receiveMessage): Updated with SendMessageQueue.
(deletePendingPieceMessage): Removed.
(getNewPieceAndSendInterest): Updated with SendMessageQueue.
(sendInterest): Updated with SendMessageQueue.
(createRequestPendingMessage): Updated with SendMessageQueue.
(sendMessages): Updated with SendMessageQueue.
(onAbort): Updated with SendMessageQueue.
(keepAlive): Updated with SendMessageQueue.
(beforeSocketCheck): Updated SendMessageQueue.
* src/PeerInteractionCommand (sendMessages): Shuffle
missingBLockIndexes before using it.
Added its own timeout for peer connection.
* src/PeerAbstractCommand.h: Added member variable timeout and
its
setter.
* src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
* src/PeerInteractionCommand.cc (PeerInteractionCommand):
Added setTimeout() call.
(executeInternal): Added setTimeout() call.
* src/PeerAbstractCommand.cc (PeerAbstractCommand):
Added timeout.
(isTimeoutDetected): Updated.
* src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry
to
option.
Added *simple* message flooding checker.
* src/PeerInteractionCommand.cc (executeInternal):
Added detectMessageFlooding() call.
(detectMessageFlooding): New function.
(receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
(beforeSocketCheck): Added detectMessageFlooding() call.
* src/PeerInteractionCommand.h: Added sendMessageQueue,
chokeUnchokeCount, haveCount, detectMessageFlooding().
Removed deletePendingPieceMessage(), getRequestSlot(),
deleteRequestSlot(), deleteAllRequestSlot().
* src/PeerInteractionCommand.cc (beforeSocketCheck):
Added checkLongTimePeerChoking() call.
* src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
* src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE
peers
if duplicate == false.
The parameter "uploaded" and "downloaded" in the tracker request
are
the size since the client sent the "started" event to the
tracker.
* src/TorrentMan.cc (setup): Assigned saved downloaded Size and
uploaded size to preDownloadedSize, preUploadedSize
respectively.
* src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
getSessionDownloadedSize(), getSessionUploadedSize().
* src/TrackerInitCommand.cc (execute): Use
getSessionDownloadedSize(),
getSessionUploadedSize() instead of getDownloadedSize(),
getUploadedSize().
* src/PendingMessage.cc (processMessage): Do not send request
message
if the peer is choking the client.
* src/TrackerUpdateCommand.cc (execute): Check wtheher
minInterval is
less than interval.
2006-03-28 15:23:51 +00:00
|
|
|
2006-03-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
Added new class SendMessageQueue that includes PendingMessages and
|
|
|
|
RequestSlotMan.
|
|
|
|
|
|
|
|
* src/SendMessageQueue.h: New class.
|
|
|
|
* src/SendMessageQueue.cc: New class.
|
|
|
|
* src/PendingMessage.h: Added new member variable blockIndex and its
|
|
|
|
accessors.
|
|
|
|
(createRequestMessage): Updated.
|
|
|
|
* src/PendingMessage.cc (createRequestMessage): Updated.
|
|
|
|
* src/PeerInteractionCommand.cc (executeInternal): Updated with
|
|
|
|
SendMessageQueue.
|
|
|
|
(checkLongTimePeerChoking): Updated with SendMessageQueue.
|
|
|
|
(receiveMessage): Updated with SendMessageQueue.
|
|
|
|
(deletePendingPieceMessage): Removed.
|
|
|
|
(getNewPieceAndSendInterest): Updated with SendMessageQueue.
|
|
|
|
(sendInterest): Updated with SendMessageQueue.
|
|
|
|
(createRequestPendingMessage): Updated with SendMessageQueue.
|
|
|
|
(sendMessages): Updated with SendMessageQueue.
|
|
|
|
(onAbort): Updated with SendMessageQueue.
|
|
|
|
(keepAlive): Updated with SendMessageQueue.
|
|
|
|
(beforeSocketCheck): Updated SendMessageQueue.
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand (sendMessages): Shuffle
|
|
|
|
missingBLockIndexes before using it.
|
|
|
|
|
|
|
|
Added its own timeout for peer connection.
|
|
|
|
|
|
|
|
* src/PeerAbstractCommand.h: Added member variable timeout and its
|
|
|
|
setter.
|
|
|
|
* src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
|
|
|
|
* src/PeerInteractionCommand.cc (PeerInteractionCommand):
|
|
|
|
Added setTimeout() call.
|
|
|
|
(executeInternal): Added setTimeout() call.
|
|
|
|
* src/PeerAbstractCommand.cc (PeerAbstractCommand):
|
|
|
|
Added timeout.
|
|
|
|
(isTimeoutDetected): Updated.
|
|
|
|
* src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry to
|
|
|
|
option.
|
|
|
|
|
|
|
|
Added *simple* message flooding checker.
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand.cc (executeInternal):
|
|
|
|
Added detectMessageFlooding() call.
|
|
|
|
(detectMessageFlooding): New function.
|
|
|
|
(receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
|
|
|
|
(beforeSocketCheck): Added detectMessageFlooding() call.
|
|
|
|
* src/PeerInteractionCommand.h: Added sendMessageQueue,
|
|
|
|
chokeUnchokeCount, haveCount, detectMessageFlooding().
|
|
|
|
Removed deletePendingPieceMessage(), getRequestSlot(),
|
|
|
|
deleteRequestSlot(), deleteAllRequestSlot().
|
|
|
|
|
|
|
|
* src/PeerInteractionCommand.cc (beforeSocketCheck):
|
|
|
|
Added checkLongTimePeerChoking() call.
|
|
|
|
|
|
|
|
* src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
|
|
|
|
|
|
|
|
* src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE peers
|
|
|
|
if duplicate == false.
|
|
|
|
|
|
|
|
The parameter "uploaded" and "downloaded" in the tracker request are
|
|
|
|
the size since the client sent the "started" event to the tracker.
|
|
|
|
|
|
|
|
* src/TorrentMan.cc (setup): Assigned saved downloaded Size and
|
|
|
|
uploaded size to preDownloadedSize, preUploadedSize respectively.
|
|
|
|
* src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
|
|
|
|
getSessionDownloadedSize(), getSessionUploadedSize().
|
|
|
|
* src/TrackerInitCommand.cc (execute): Use getSessionDownloadedSize(),
|
|
|
|
getSessionUploadedSize() instead of getDownloadedSize(),
|
|
|
|
getUploadedSize().
|
|
|
|
|
|
|
|
* src/PendingMessage.cc (processMessage): Do not send request message
|
|
|
|
if the peer is choking the client.
|
|
|
|
|
|
|
|
* src/TrackerUpdateCommand.cc (execute): Check wtheher minInterval is
|
|
|
|
less than interval.
|
|
|
|
|
2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* configure.in: Added gnutls support. Added several CPP macros.
* m4/openssl.m4: Added.
* src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
readData(), peekData(). Added gnutls support.
* src/HttpDownloadCommand.cc: Removed SleepCommand.h
* src/TrackerWatcherCommand.{h,cc}: Added. This command creates
TrackerInitCommand periodicaly(TorrentMan::minInterval).
* src/TorrentMan.cc: Remove downloadedSize == 0 check from
save().
Instead, added a check for whether setup method has executed
successfully.
* src/TorrentMan.h: Added member vaiable setupComplete. Updated
DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to
300.
* src/Makefile.am: Updated.
* src/messageDigest.h: Added. This is a macro calculating SHA1
digest
using whether OpenSSL or gcrypt, depending on the result of
configure
script.
* src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by
using
messageDigest.h.
* src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
* src/PeerListenCommand.cc: Added log about port binded
successfully.
Fixed memory leak.
* src/main.cc: Added gnutls support. Replaced LIB_SSL with
ENABLE_BITTORRENT where they are not related to OpenSSL but
BitTorrent.
Removed instantiation of TrackerInitCommand. Instead,
TrackerWatcherCommand is instantiated and pushed to the command
queue.
* src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL
with
ENABLE_SSL.
* src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
* src/RequestSlotMan.cc:
(deleteCompletedRequestSlot)
If a piece is already acquired by another command, delete the
request
slots for the piece.
* src/TrackerUpdateCommand.cc:
(execute)
Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to
warn.
Added a check whether peer list is null.
Fixed the bug that causes sending completed event to the tracker
several times.
* src/TrackerInitCommand.cc:
(execute)
Fixed the bug that causes sending completed event to the tracker
several times.
* src/AbstractDiskWriter.{h,cc}: Removed direct dependency on
OpenSSL
by using messageDigest.h.
2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* PeerConnection.cc: Replaced log message "keep-alive" with
"keep alive".
* PeerInteractionCommand.{h,cc}: Close connection if peer is
choking
localhost long time.
* TorrentMan.cc: When adding new peer with duplicate = true, if
the
number of peer list is equal to or grater than MAX_PEER_LIST,
delete
at most 100 failure entry from the list. If with duplicate =
false,
MAX_PEER_LIST is not checked.
* PeerListenCommand.cc: Fixed the argument order of log message.
2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
Added warn().
* SimpleLogger.h: Moved enum LEVEL to Logger.h.
Implemented warn().
Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated
code.
2006-03-27 14:47:26 +00:00
|
|
|
2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* configure.in: Added gnutls support. Added several CPP macros.
|
|
|
|
* m4/openssl.m4: Added.
|
|
|
|
* src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
|
|
|
|
readData(), peekData(). Added gnutls support.
|
|
|
|
* src/HttpDownloadCommand.cc: Removed SleepCommand.h
|
|
|
|
* src/TrackerWatcherCommand.{h,cc}: Added. This command creates
|
|
|
|
TrackerInitCommand periodicaly(TorrentMan::minInterval).
|
|
|
|
* src/TorrentMan.cc: Remove downloadedSize == 0 check from save().
|
|
|
|
Instead, added a check for whether setup method has executed
|
|
|
|
successfully.
|
|
|
|
* src/TorrentMan.h: Added member vaiable setupComplete. Updated
|
|
|
|
DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to 300.
|
|
|
|
* src/Makefile.am: Updated.
|
|
|
|
* src/messageDigest.h: Added. This is a macro calculating SHA1 digest
|
|
|
|
using whether OpenSSL or gcrypt, depending on the result of configure
|
|
|
|
script.
|
|
|
|
* src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by using
|
|
|
|
messageDigest.h.
|
|
|
|
* src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
|
|
|
|
* src/PeerListenCommand.cc: Added log about port binded successfully.
|
|
|
|
Fixed memory leak.
|
|
|
|
* src/main.cc: Added gnutls support. Replaced LIB_SSL with
|
|
|
|
ENABLE_BITTORRENT where they are not related to OpenSSL but BitTorrent.
|
|
|
|
Removed instantiation of TrackerInitCommand. Instead,
|
|
|
|
TrackerWatcherCommand is instantiated and pushed to the command queue.
|
|
|
|
* src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL with
|
|
|
|
ENABLE_SSL.
|
|
|
|
* src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
|
Added new class SendMessageQueue that includes PendingMessages
and
RequestSlotMan.
* src/SendMessageQueue.h: New class.
* src/SendMessageQueue.cc: New class.
* src/PendingMessage.h: Added new member variable blockIndex and
its
accessors.
(createRequestMessage): Updated.
* src/PendingMessage.cc (createRequestMessage): Updated.
* src/PeerInteractionCommand.cc (executeInternal): Updated with
SendMessageQueue.
(checkLongTimePeerChoking): Updated with SendMessageQueue.
(receiveMessage): Updated with SendMessageQueue.
(deletePendingPieceMessage): Removed.
(getNewPieceAndSendInterest): Updated with SendMessageQueue.
(sendInterest): Updated with SendMessageQueue.
(createRequestPendingMessage): Updated with SendMessageQueue.
(sendMessages): Updated with SendMessageQueue.
(onAbort): Updated with SendMessageQueue.
(keepAlive): Updated with SendMessageQueue.
(beforeSocketCheck): Updated SendMessageQueue.
* src/PeerInteractionCommand (sendMessages): Shuffle
missingBLockIndexes before using it.
Added its own timeout for peer connection.
* src/PeerAbstractCommand.h: Added member variable timeout and
its
setter.
* src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
* src/PeerInteractionCommand.cc (PeerInteractionCommand):
Added setTimeout() call.
(executeInternal): Added setTimeout() call.
* src/PeerAbstractCommand.cc (PeerAbstractCommand):
Added timeout.
(isTimeoutDetected): Updated.
* src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry
to
option.
Added *simple* message flooding checker.
* src/PeerInteractionCommand.cc (executeInternal):
Added detectMessageFlooding() call.
(detectMessageFlooding): New function.
(receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
(beforeSocketCheck): Added detectMessageFlooding() call.
* src/PeerInteractionCommand.h: Added sendMessageQueue,
chokeUnchokeCount, haveCount, detectMessageFlooding().
Removed deletePendingPieceMessage(), getRequestSlot(),
deleteRequestSlot(), deleteAllRequestSlot().
* src/PeerInteractionCommand.cc (beforeSocketCheck):
Added checkLongTimePeerChoking() call.
* src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
* src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE
peers
if duplicate == false.
The parameter "uploaded" and "downloaded" in the tracker request
are
the size since the client sent the "started" event to the
tracker.
* src/TorrentMan.cc (setup): Assigned saved downloaded Size and
uploaded size to preDownloadedSize, preUploadedSize
respectively.
* src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
getSessionDownloadedSize(), getSessionUploadedSize().
* src/TrackerInitCommand.cc (execute): Use
getSessionDownloadedSize(),
getSessionUploadedSize() instead of getDownloadedSize(),
getUploadedSize().
* src/PendingMessage.cc (processMessage): Do not send request
message
if the peer is choking the client.
* src/TrackerUpdateCommand.cc (execute): Check wtheher
minInterval is
less than interval.
2006-03-28 15:23:51 +00:00
|
|
|
* src/RequestSlotMan.cc (deleteCompletedRequestSlot):
|
2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* configure.in: Added gnutls support. Added several CPP macros.
* m4/openssl.m4: Added.
* src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
readData(), peekData(). Added gnutls support.
* src/HttpDownloadCommand.cc: Removed SleepCommand.h
* src/TrackerWatcherCommand.{h,cc}: Added. This command creates
TrackerInitCommand periodicaly(TorrentMan::minInterval).
* src/TorrentMan.cc: Remove downloadedSize == 0 check from
save().
Instead, added a check for whether setup method has executed
successfully.
* src/TorrentMan.h: Added member vaiable setupComplete. Updated
DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to
300.
* src/Makefile.am: Updated.
* src/messageDigest.h: Added. This is a macro calculating SHA1
digest
using whether OpenSSL or gcrypt, depending on the result of
configure
script.
* src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by
using
messageDigest.h.
* src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
* src/PeerListenCommand.cc: Added log about port binded
successfully.
Fixed memory leak.
* src/main.cc: Added gnutls support. Replaced LIB_SSL with
ENABLE_BITTORRENT where they are not related to OpenSSL but
BitTorrent.
Removed instantiation of TrackerInitCommand. Instead,
TrackerWatcherCommand is instantiated and pushed to the command
queue.
* src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL
with
ENABLE_SSL.
* src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
* src/RequestSlotMan.cc:
(deleteCompletedRequestSlot)
If a piece is already acquired by another command, delete the
request
slots for the piece.
* src/TrackerUpdateCommand.cc:
(execute)
Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to
warn.
Added a check whether peer list is null.
Fixed the bug that causes sending completed event to the tracker
several times.
* src/TrackerInitCommand.cc:
(execute)
Fixed the bug that causes sending completed event to the tracker
several times.
* src/AbstractDiskWriter.{h,cc}: Removed direct dependency on
OpenSSL
by using messageDigest.h.
2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* PeerConnection.cc: Replaced log message "keep-alive" with
"keep alive".
* PeerInteractionCommand.{h,cc}: Close connection if peer is
choking
localhost long time.
* TorrentMan.cc: When adding new peer with duplicate = true, if
the
number of peer list is equal to or grater than MAX_PEER_LIST,
delete
at most 100 failure entry from the list. If with duplicate =
false,
MAX_PEER_LIST is not checked.
* PeerListenCommand.cc: Fixed the argument order of log message.
2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
Added warn().
* SimpleLogger.h: Moved enum LEVEL to Logger.h.
Implemented warn().
Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated
code.
2006-03-27 14:47:26 +00:00
|
|
|
If a piece is already acquired by another command, delete the request
|
|
|
|
slots for the piece.
|
Added new class SendMessageQueue that includes PendingMessages
and
RequestSlotMan.
* src/SendMessageQueue.h: New class.
* src/SendMessageQueue.cc: New class.
* src/PendingMessage.h: Added new member variable blockIndex and
its
accessors.
(createRequestMessage): Updated.
* src/PendingMessage.cc (createRequestMessage): Updated.
* src/PeerInteractionCommand.cc (executeInternal): Updated with
SendMessageQueue.
(checkLongTimePeerChoking): Updated with SendMessageQueue.
(receiveMessage): Updated with SendMessageQueue.
(deletePendingPieceMessage): Removed.
(getNewPieceAndSendInterest): Updated with SendMessageQueue.
(sendInterest): Updated with SendMessageQueue.
(createRequestPendingMessage): Updated with SendMessageQueue.
(sendMessages): Updated with SendMessageQueue.
(onAbort): Updated with SendMessageQueue.
(keepAlive): Updated with SendMessageQueue.
(beforeSocketCheck): Updated SendMessageQueue.
* src/PeerInteractionCommand (sendMessages): Shuffle
missingBLockIndexes before using it.
Added its own timeout for peer connection.
* src/PeerAbstractCommand.h: Added member variable timeout and
its
setter.
* src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
* src/PeerInteractionCommand.cc (PeerInteractionCommand):
Added setTimeout() call.
(executeInternal): Added setTimeout() call.
* src/PeerAbstractCommand.cc (PeerAbstractCommand):
Added timeout.
(isTimeoutDetected): Updated.
* src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry
to
option.
Added *simple* message flooding checker.
* src/PeerInteractionCommand.cc (executeInternal):
Added detectMessageFlooding() call.
(detectMessageFlooding): New function.
(receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
(beforeSocketCheck): Added detectMessageFlooding() call.
* src/PeerInteractionCommand.h: Added sendMessageQueue,
chokeUnchokeCount, haveCount, detectMessageFlooding().
Removed deletePendingPieceMessage(), getRequestSlot(),
deleteRequestSlot(), deleteAllRequestSlot().
* src/PeerInteractionCommand.cc (beforeSocketCheck):
Added checkLongTimePeerChoking() call.
* src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
* src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE
peers
if duplicate == false.
The parameter "uploaded" and "downloaded" in the tracker request
are
the size since the client sent the "started" event to the
tracker.
* src/TorrentMan.cc (setup): Assigned saved downloaded Size and
uploaded size to preDownloadedSize, preUploadedSize
respectively.
* src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
getSessionDownloadedSize(), getSessionUploadedSize().
* src/TrackerInitCommand.cc (execute): Use
getSessionDownloadedSize(),
getSessionUploadedSize() instead of getDownloadedSize(),
getUploadedSize().
* src/PendingMessage.cc (processMessage): Do not send request
message
if the peer is choking the client.
* src/TrackerUpdateCommand.cc (execute): Check wtheher
minInterval is
less than interval.
2006-03-28 15:23:51 +00:00
|
|
|
* src/TrackerUpdateCommand.cc (execute):
|
2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* configure.in: Added gnutls support. Added several CPP macros.
* m4/openssl.m4: Added.
* src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
readData(), peekData(). Added gnutls support.
* src/HttpDownloadCommand.cc: Removed SleepCommand.h
* src/TrackerWatcherCommand.{h,cc}: Added. This command creates
TrackerInitCommand periodicaly(TorrentMan::minInterval).
* src/TorrentMan.cc: Remove downloadedSize == 0 check from
save().
Instead, added a check for whether setup method has executed
successfully.
* src/TorrentMan.h: Added member vaiable setupComplete. Updated
DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to
300.
* src/Makefile.am: Updated.
* src/messageDigest.h: Added. This is a macro calculating SHA1
digest
using whether OpenSSL or gcrypt, depending on the result of
configure
script.
* src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by
using
messageDigest.h.
* src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
* src/PeerListenCommand.cc: Added log about port binded
successfully.
Fixed memory leak.
* src/main.cc: Added gnutls support. Replaced LIB_SSL with
ENABLE_BITTORRENT where they are not related to OpenSSL but
BitTorrent.
Removed instantiation of TrackerInitCommand. Instead,
TrackerWatcherCommand is instantiated and pushed to the command
queue.
* src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL
with
ENABLE_SSL.
* src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
* src/RequestSlotMan.cc:
(deleteCompletedRequestSlot)
If a piece is already acquired by another command, delete the
request
slots for the piece.
* src/TrackerUpdateCommand.cc:
(execute)
Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to
warn.
Added a check whether peer list is null.
Fixed the bug that causes sending completed event to the tracker
several times.
* src/TrackerInitCommand.cc:
(execute)
Fixed the bug that causes sending completed event to the tracker
several times.
* src/AbstractDiskWriter.{h,cc}: Removed direct dependency on
OpenSSL
by using messageDigest.h.
2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* PeerConnection.cc: Replaced log message "keep-alive" with
"keep alive".
* PeerInteractionCommand.{h,cc}: Close connection if peer is
choking
localhost long time.
* TorrentMan.cc: When adding new peer with duplicate = true, if
the
number of peer list is equal to or grater than MAX_PEER_LIST,
delete
at most 100 failure entry from the list. If with duplicate =
false,
MAX_PEER_LIST is not checked.
* PeerListenCommand.cc: Fixed the argument order of log message.
2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
Added warn().
* SimpleLogger.h: Moved enum LEVEL to Logger.h.
Implemented warn().
Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated
code.
2006-03-27 14:47:26 +00:00
|
|
|
Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to warn.
|
|
|
|
Added a check whether peer list is null.
|
|
|
|
Fixed the bug that causes sending completed event to the tracker
|
|
|
|
several times.
|
Added new class SendMessageQueue that includes PendingMessages
and
RequestSlotMan.
* src/SendMessageQueue.h: New class.
* src/SendMessageQueue.cc: New class.
* src/PendingMessage.h: Added new member variable blockIndex and
its
accessors.
(createRequestMessage): Updated.
* src/PendingMessage.cc (createRequestMessage): Updated.
* src/PeerInteractionCommand.cc (executeInternal): Updated with
SendMessageQueue.
(checkLongTimePeerChoking): Updated with SendMessageQueue.
(receiveMessage): Updated with SendMessageQueue.
(deletePendingPieceMessage): Removed.
(getNewPieceAndSendInterest): Updated with SendMessageQueue.
(sendInterest): Updated with SendMessageQueue.
(createRequestPendingMessage): Updated with SendMessageQueue.
(sendMessages): Updated with SendMessageQueue.
(onAbort): Updated with SendMessageQueue.
(keepAlive): Updated with SendMessageQueue.
(beforeSocketCheck): Updated SendMessageQueue.
* src/PeerInteractionCommand (sendMessages): Shuffle
missingBLockIndexes before using it.
Added its own timeout for peer connection.
* src/PeerAbstractCommand.h: Added member variable timeout and
its
setter.
* src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
* src/PeerInteractionCommand.cc (PeerInteractionCommand):
Added setTimeout() call.
(executeInternal): Added setTimeout() call.
* src/PeerAbstractCommand.cc (PeerAbstractCommand):
Added timeout.
(isTimeoutDetected): Updated.
* src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry
to
option.
Added *simple* message flooding checker.
* src/PeerInteractionCommand.cc (executeInternal):
Added detectMessageFlooding() call.
(detectMessageFlooding): New function.
(receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
(beforeSocketCheck): Added detectMessageFlooding() call.
* src/PeerInteractionCommand.h: Added sendMessageQueue,
chokeUnchokeCount, haveCount, detectMessageFlooding().
Removed deletePendingPieceMessage(), getRequestSlot(),
deleteRequestSlot(), deleteAllRequestSlot().
* src/PeerInteractionCommand.cc (beforeSocketCheck):
Added checkLongTimePeerChoking() call.
* src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
* src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE
peers
if duplicate == false.
The parameter "uploaded" and "downloaded" in the tracker request
are
the size since the client sent the "started" event to the
tracker.
* src/TorrentMan.cc (setup): Assigned saved downloaded Size and
uploaded size to preDownloadedSize, preUploadedSize
respectively.
* src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
getSessionDownloadedSize(), getSessionUploadedSize().
* src/TrackerInitCommand.cc (execute): Use
getSessionDownloadedSize(),
getSessionUploadedSize() instead of getDownloadedSize(),
getUploadedSize().
* src/PendingMessage.cc (processMessage): Do not send request
message
if the peer is choking the client.
* src/TrackerUpdateCommand.cc (execute): Check wtheher
minInterval is
less than interval.
2006-03-28 15:23:51 +00:00
|
|
|
* src/TrackerInitCommand.cc (execute):
|
2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* configure.in: Added gnutls support. Added several CPP macros.
* m4/openssl.m4: Added.
* src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
readData(), peekData(). Added gnutls support.
* src/HttpDownloadCommand.cc: Removed SleepCommand.h
* src/TrackerWatcherCommand.{h,cc}: Added. This command creates
TrackerInitCommand periodicaly(TorrentMan::minInterval).
* src/TorrentMan.cc: Remove downloadedSize == 0 check from
save().
Instead, added a check for whether setup method has executed
successfully.
* src/TorrentMan.h: Added member vaiable setupComplete. Updated
DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to
300.
* src/Makefile.am: Updated.
* src/messageDigest.h: Added. This is a macro calculating SHA1
digest
using whether OpenSSL or gcrypt, depending on the result of
configure
script.
* src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by
using
messageDigest.h.
* src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
* src/PeerListenCommand.cc: Added log about port binded
successfully.
Fixed memory leak.
* src/main.cc: Added gnutls support. Replaced LIB_SSL with
ENABLE_BITTORRENT where they are not related to OpenSSL but
BitTorrent.
Removed instantiation of TrackerInitCommand. Instead,
TrackerWatcherCommand is instantiated and pushed to the command
queue.
* src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL
with
ENABLE_SSL.
* src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
* src/RequestSlotMan.cc:
(deleteCompletedRequestSlot)
If a piece is already acquired by another command, delete the
request
slots for the piece.
* src/TrackerUpdateCommand.cc:
(execute)
Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to
warn.
Added a check whether peer list is null.
Fixed the bug that causes sending completed event to the tracker
several times.
* src/TrackerInitCommand.cc:
(execute)
Fixed the bug that causes sending completed event to the tracker
several times.
* src/AbstractDiskWriter.{h,cc}: Removed direct dependency on
OpenSSL
by using messageDigest.h.
2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* PeerConnection.cc: Replaced log message "keep-alive" with
"keep alive".
* PeerInteractionCommand.{h,cc}: Close connection if peer is
choking
localhost long time.
* TorrentMan.cc: When adding new peer with duplicate = true, if
the
number of peer list is equal to or grater than MAX_PEER_LIST,
delete
at most 100 failure entry from the list. If with duplicate =
false,
MAX_PEER_LIST is not checked.
* PeerListenCommand.cc: Fixed the argument order of log message.
2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
Added warn().
* SimpleLogger.h: Moved enum LEVEL to Logger.h.
Implemented warn().
Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated
code.
2006-03-27 14:47:26 +00:00
|
|
|
Fixed the bug that causes sending completed event to the tracker
|
|
|
|
several times.
|
|
|
|
* src/AbstractDiskWriter.{h,cc}: Removed direct dependency on OpenSSL
|
|
|
|
by using messageDigest.h.
|
|
|
|
|
|
|
|
2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* PeerConnection.cc: Replaced log message "keep-alive" with
|
|
|
|
"keep alive".
|
|
|
|
* PeerInteractionCommand.{h,cc}: Close connection if peer is choking
|
|
|
|
localhost long time.
|
|
|
|
* TorrentMan.cc: When adding new peer with duplicate = true, if the
|
|
|
|
number of peer list is equal to or grater than MAX_PEER_LIST, delete
|
|
|
|
at most 100 failure entry from the list. If with duplicate = false,
|
|
|
|
MAX_PEER_LIST is not checked.
|
|
|
|
* PeerListenCommand.cc: Fixed the argument order of log message.
|
|
|
|
|
|
|
|
2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
|
|
|
|
Added warn().
|
|
|
|
* SimpleLogger.h: Moved enum LEVEL to Logger.h.
|
|
|
|
Implemented warn().
|
|
|
|
Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated code.
|
|
|
|
|
2006-03-24 11:59:18 +00:00
|
|
|
2006-03-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* Request.h: Added AFTER_COMPLETED event.
|
|
|
|
* TorrentDownloadEngine.cc: Prints "Download complete" message
|
|
|
|
instead of downloaded size and progress(%) after download completes.
|
|
|
|
* PeerInteractionCommand.cc: After download completes, sends unchoke
|
|
|
|
message to the peer if it is interested in what localhost has
|
|
|
|
downloaded.
|
|
|
|
* TorrentMan.cc: In single-file mode, copy temporary file to the final
|
|
|
|
destination instead of just renaming it.
|
|
|
|
* TorrentMan.cc: Added deleteTempFile().
|
|
|
|
* PeerAbstractCommand.cc: do not stop execution after download
|
|
|
|
completes. This makes localhost a seeder.
|
|
|
|
* Util.{h,cc}: Added fileCopy().
|
|
|
|
* PeerListenCommand.cc: do not stop execution after download completes.
|
|
|
|
This makes localhost a seeder.
|
|
|
|
* main.cc: Do not call TorrentMan::fixFilename() in torrentHandler.
|
|
|
|
Added TorrentMan::deleteTempFile() to torrentHandler.
|
|
|
|
Initialized the variable dir as ".".
|
|
|
|
* TorrentMan.h: Changed DEFAULT_ANNOUNCE_INTERVAL to 120 seconds.
|
|
|
|
Deleted renameSingleFile().
|
|
|
|
Added copySingleFile(), deleteTempFile().
|
|
|
|
* DownloadEngine.h: Added virtual function afterEachIteration().
|
|
|
|
* TorrentDownloadEngine.cc: Move a call to TorrentMan::fixFilename()
|
|
|
|
in onEndOfRun() to afterEachIteration().
|
|
|
|
In onEndOfRun(), changed if condition to check whether filenameFixed is
|
|
|
|
true.
|
|
|
|
* Util.cc: Implemented fileCopy() using rangedFileCopy().
|
|
|
|
In rangedFileCopy(), added try-catch block to properly close file
|
|
|
|
descriptors.
|
|
|
|
* TorrentDownloadEngine.cc: Added a member variable filenameFixed.
|
|
|
|
Added afterEachIteration(), isFilenameFixed().
|
|
|
|
* Peer.cc: Changed choking strategy.
|
|
|
|
* PreAllocationDiskWriter.cc: Drop O_DIRECT flag.
|
|
|
|
* TrackerInitCommand.cc: Send completed event only once.
|
|
|
|
* DownloadEngine.cc: Added a call to afterEachIteration().
|
|
|
|
* TrackerUpdateCommand.cc: Do not stop execution after download
|
|
|
|
completes.
|
|
|
|
* TorrentMan.h: Defined MAX_PEER_UPDATE as 15. aria2 attempts to
|
|
|
|
connect the peers at most MAX_PEER_UPDATE when a peer list is
|
|
|
|
received from a tracker.
|
|
|
|
* TrackerUpdateCommand.cc: Implemented above mentioned behavior.
|
|
|
|
Decreased the number of failure peers to delete to 0(just comment out
|
|
|
|
the line).
|
|
|
|
* Release 0.3.1
|
|
|
|
|
2006-03-22 15:10:03 +00:00
|
|
|
2006-03-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* PeerInteractionCommand.cc: added a call to
|
|
|
|
TorrentMan::unadvertisePiece in Destructor.
|
|
|
|
* PeerInteractionCommand.cc: make have message sent immediately
|
|
|
|
if the size of pending message queue is zero.
|
|
|
|
* TorrentMan.cc: set the maximum size of peer list to 250.
|
|
|
|
* TorrentMan.h: changed the container type of Peers and UsedPieces
|
|
|
|
to deque.
|
|
|
|
* Util.cc: fixed rangedFileCopy.
|
|
|
|
* AbstractDiskWriter.{h,cc}: moved digest context initialization
|
|
|
|
to Constructor. Also, moved digest cleanup to Destructor.
|
|
|
|
* MetaFileUtil.cc: fixed memory leak
|
2006-03-22 16:21:11 +00:00
|
|
|
* replaced std::vector with std::deque.
|
2006-03-23 10:47:25 +00:00
|
|
|
* AbstractCommand.cc: casted timeout value to long long int.
|
|
|
|
* ChunkedEncoding.cc: fixed memory leak.
|
|
|
|
* PeerInteractionCommand.cc: casted timeout value to long long int.
|
|
|
|
* SleepCommand.cc: casted timeout value to long long int.
|
|
|
|
* Data.cc: fixed memory leak.
|
|
|
|
* Data.cc: fixed toLLInt().
|
|
|
|
* BitfieldMan.cc: fixed memory leak.
|
|
|
|
* TorrentMan.cc: initialized storeDir to ".".
|
|
|
|
* TorrentMan.cc: fixed memory leak.
|
|
|
|
* TorrentMan.cc: corrected file paths of splitted files.
|
|
|
|
* PeerAbstractCommand.cc: casted timeout to long long int.
|
|
|
|
* main.cc: added delete(req) and delete(te->diskWriter).
|
|
|
|
* RequestSlot.cc: casted timeout value to long long int.
|
|
|
|
* Request.cc: fixed memory leak.
|
|
|
|
* PendingMessage.cc: make HAVE messages sent only when peer does not
|
|
|
|
have the piece.
|
|
|
|
* Peer.{h,cc}: added hasPiece(int index).
|
2006-03-23 11:04:43 +00:00
|
|
|
* main.cc: corrected addCommand.
|
2006-03-22 15:10:03 +00:00
|
|
|
|
2006-03-21 15:21:11 +00:00
|
|
|
2006-03-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* BitTorrent protocol support added.
|
2006-03-24 11:59:18 +00:00
|
|
|
* Release 0.3.0
|
|
|
|
|
2006-03-21 14:12:51 +00:00
|
|
|
2006-03-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* SocketCore.cc: remove the assignment of addrinfo.ai_addr.
|
|
|
|
|
2006-03-09 14:52:07 +00:00
|
|
|
2006-03-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* ChunkedEncoding.{h,cc}: fixed the bug that if chunk data is binary,
|
|
|
|
decoding did not work properly.
|
|
|
|
|
2006-03-07 13:33:43 +00:00
|
|
|
2006-03-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
2006-03-07 13:08:09 +00:00
|
|
|
|
2006-03-07 13:33:43 +00:00
|
|
|
* DownloadEngine.h: included sys/time.h
|
|
|
|
* DownloadEngine.cc: remove sys/time.h
|
2006-03-07 13:08:09 +00:00
|
|
|
* Makefile.am (SUBDIRS): Add intl.
|
|
|
|
* configure.in (AC_CONFIG_FILES): Add intl/Makefile.
|
|
|
|
|
2006-03-05 06:32:01 +00:00
|
|
|
2006-03-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* main.cc: correct help message for --http-auth-scheme.
|
|
|
|
* main.cc: changed e-mail address for bug reports.
|
|
|
|
* ja.po: added japanese translation.
|
|
|
|
|
|
|
|
2006-03-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* SimpleLogger.cc: flush log file instead of stdout.
|
|
|
|
|
|
|
|
2006-03-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* main.cc: Fixed command-line option: max-tries
|
|
|
|
* HttpResponseCommand.cc: Make the request re-sent only if req->seg.sp
|
|
|
|
does not equal to seg.sp.
|
|
|
|
* DownloadCommand.cc: If EOF is got from the server and the total size
|
|
|
|
of file is not zero, then throw DlRetryEx.
|
|
|
|
* main.cc: Set the minium value of min-segment-size to 1024.
|
|
|
|
* HttpResponseCommand.cc: Fixed the bug that http segmented downloading
|
|
|
|
fails because of a regression since 0.2.0 release.
|
|
|
|
|
2006-03-01 15:28:31 +00:00
|
|
|
2006-03-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* HttpConnection.cc:
|
|
|
|
* common.h: defined the user agent name as macro
|
2006-03-02 02:54:49 +00:00
|
|
|
* DownloadEngine.{h, cc}:
|
|
|
|
* ConsoleDownloadEngine.{h, cc}: Console output message(size, speed)
|
|
|
|
is now generated by ConsoleDownloadEngine not by DownloadEngine.
|
|
|
|
* main.cc: Download complete/abort message is now generated by main.
|
2006-03-02 10:43:00 +00:00
|
|
|
* Makefile.am (SUBDIRS): Add m4.
|
|
|
|
(ACLOCAL_AMFLAGS): New variable.
|
|
|
|
(EXTRA_DIST): New variable.
|
|
|
|
* configure.in (AC_CONFIG_FILES): Add po/Makefile.in,
|
|
|
|
* gettext: added gettext functionality
|
2006-03-02 02:54:49 +00:00
|
|
|
|
2006-03-01 02:26:29 +00:00
|
|
|
2006-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* AbstractCommand.cc:
|
|
|
|
* DownloadCommand.{h, cc}: Aborted downloading commands now properly
|
|
|
|
unregister its cuid from SegmentMan.
|
|
|
|
* DownloadEngine.cc: .aria2 file was written when a downloading
|
|
|
|
failed with errors.
|
2006-03-01 07:00:39 +00:00
|
|
|
* HttpConnection.cc: Added "Proxy-Connection" header to proxy request.
|
|
|
|
Added "User-Agent" header to CONNECT proxy request.
|
|
|
|
Fixed "Proxy-Authorization" header. Now proxy authorization works
|
|
|
|
properly.
|
2006-03-01 07:14:52 +00:00
|
|
|
* Logger.h:
|
|
|
|
* SimpleLogger.{h,cc}: Changed the type of msg to const char*.
|
2006-03-01 07:46:21 +00:00
|
|
|
* ChunkedEncoding.cc: Added #include directive for strings.h
|
2006-03-01 08:28:57 +00:00
|
|
|
* Release 0.2.1
|
2006-03-01 02:26:29 +00:00
|
|
|
|
2006-02-28 02:25:45 +00:00
|
|
|
2006-02-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* Util.{h,cc}: added startsWith().
|
|
|
|
* CookieBox.cc: rewrited criteriaFind() using Util::startsWith() and
|
|
|
|
Util::endsWith().
|
|
|
|
* SocketCore.cc: struct addrinfo is now zero-initialized.
|
|
|
|
* common.h: added #include directive of limit.h.
|
|
|
|
* DownloadEngine.cc: added #include directive of sys/time.h and
|
|
|
|
algorithm.
|
|
|
|
* Exception.h: added #include directive of stdio.h.
|
|
|
|
* AbstractCommand.h: added #include directive of sys/time.h.
|
|
|
|
* DownloadCommand.h: added #include directive of sys/time.h.
|
|
|
|
* *.h: added #include directive of common.h to all base classes.
|
|
|
|
subclasses' one was removed.
|
2006-02-28 03:09:22 +00:00
|
|
|
* common.h: defined LONG_LONG_MAX and LONG_LONG_MIN if a compiler
|
|
|
|
does not define these macros.
|
2006-02-28 02:25:45 +00:00
|
|
|
|
2006-02-22 15:40:04 +00:00
|
|
|
2006-02-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* Release 0.2.0
|
|
|
|
* main.cc:
|
|
|
|
* HttpInitiateConnectionCommand.{h,cc}:
|
|
|
|
* prefs.h:
|
|
|
|
* HttpConnection.{h,cc}: added --http-proxy-method option.
|
|
|
|
We can now use GET command in http proxy.
|
2006-02-22 12:16:10 +00:00
|
|
|
|
2006-02-22 15:40:04 +00:00
|
|
|
2006-02-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
2006-02-22 14:30:47 +00:00
|
|
|
* SplitSlowestSegmentSplitter.{h,cc}: This class provies algorithm
|
|
|
|
that splits slowest segment of SegmentMan::commands vector.
|
|
|
|
This is the default split algorithm of aria2.
|
|
|
|
* SplitFirstSegmentSplitter.{h,cc}: This class provides algorithm
|
|
|
|
that splits first segment of SegmentMan::commands vector.
|
|
|
|
* SegmentSplitter.{h,cc}: Added. This class provides split algorithm.
|
|
|
|
* DownloadCommand.{h,cc}: Added downloading speed calculation.
|
|
|
|
* Segment.h:
|
|
|
|
* SegmentMan.cc: Added speed field to Segment.h
|
2006-02-22 12:16:10 +00:00
|
|
|
* main.cc: -s option now affects all URLs in command-line arguemtns.
|
|
|
|
* HttpResponseCommand.cc: Fixed bug that segment file is not loaded.
|
|
|
|
* message.h: Change file size related %d to %lld.
|
|
|
|
|
2006-02-21 15:01:05 +00:00
|
|
|
2006-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
|
|
|
* FtpInitiateConnectionCommand.{h,cc}:
|
|
|
|
* FtpNegotiationCommand.{h,cc}:
|
|
|
|
* FtpDownloadCommand.{h,cc}:
|
|
|
|
* FtpConnection.{h,cc}: Added FTP support
|
|
|
|
* SimpleLogger.cc: Log message now includes time information.
|
|
|
|
* main.cc: The value of --http-auth-scheme option is chagned from
|
|
|
|
'BASIC' to 'basic'
|
|
|
|
* main.cc: Added --timeout command-line option.
|
2006-02-22 11:18:47 +00:00
|
|
|
* main.cc: Added --min-segment-size command-line option.
|
|
|
|
* main.cc: Added --max-retries command-line option.
|
2006-02-21 15:01:05 +00:00
|
|
|
* prefs.h: option string constants are now defined in prefs.h
|
|
|
|
|
2006-02-21 12:27:17 +00:00
|
|
|
2006-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
2006-02-21 15:01:05 +00:00
|
|
|
* AbstractCommand.cc: Fixed timeout bug in AbstractCommand
|
|
|
|
* SegmentMan.cc: Added totalSize entry to .aria2 file. No compatibility
|
|
|
|
with version 0.1.0's one.
|
2006-02-21 12:27:17 +00:00
|
|
|
|
2006-02-17 18:51:12 +00:00
|
|
|
2006-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
|
|
|
|
2006-02-21 15:01:05 +00:00
|
|
|
* configure.in: Added --enable-ssl option to configure script.
|
|
|
|
* HttpConnection.cc: Make Request-URI an absolute path. Some servers
|
|
|
|
cannot permit absoluteURI as Request-URI.
|
|
|
|
* HttpConnection.cc: Added Referer support.
|
|
|
|
* main.cc: Added referer command-line option.
|
|
|
|
* main.cc: Added rety-wait command-line option.
|
|
|
|
* Exception.h: Fixed formating bug in Exception::setMsg()
|
|
|
|
* SocketCore.{h,cc}:
|
|
|
|
* Socket.{h, cc}:
|
|
|
|
* Request.cc:
|
|
|
|
* InitiateConnectionCommandFactory.cc:
|
|
|
|
* HttpRequestCommand.cc: Added HTTPS support.
|
|
|
|
* SocketCore.{h,cc}: Added SocketCore. Socket becomes a handle class
|
|
|
|
for SocketCore.
|
|
|
|
* ChunkedEncoding.cc: Fixed bug in ChunkedEncoding: expanding buffer
|
|
|
|
size is wrong
|
|
|
|
* DownloadCommand.cc: Fixed bug in DownloadCommand: In Chunked
|
|
|
|
Encoding, it wrongly adds to Segment.ds buff length from the socket.
|
2006-02-17 18:51:12 +00:00
|
|
|
|
2006-02-17 13:35:04 +00:00
|
|
|
2006-02-17 Tatsuhiro Tsujikawa <tsujikawa at rednoah dot com>
|
2006-02-17 18:51:12 +00:00
|
|
|
|
|
|
|
* Release 0.1.0
|
2006-02-17 13:35:04 +00:00
|
|
|
|