Commit Graph

830 Commits (e9e215dc1f37827fabd87d6fb7ed99afa843d53a)

Author SHA1 Message Date
Tatsuhiro Tsujikawa e9e215dc1f 2008-09-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that HTTPS download fails.
	* src/AbstractCommand.cc
	* src/AbstractCommand.h
	* src/DownloadCommand.cc
	* src/FtpConnection.cc
	* src/HttpConnection.cc
	* src/HttpRequestCommand.cc
	* src/HttpResponseCommand.cc
	* src/HttpSkipResponseCommand.cc
	* src/MSEHandshake.cc
	* src/PeerConnection.cc
	* src/SocketCore.cc
	* src/SocketCore.h

	Fixed the bug that aria2 doesn't download whole content body and 
cannot
	reuse connection if chunked transfer encoding and gzip content 
encoding
	are set.
	* src/DownloadCommand.cc
	* src/HttpSkipResponseCommand.cc
2008-09-27 16:06:34 +00:00
Tatsuhiro Tsujikawa 080fcd5fb8 2008-09-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Updated man page.
	* doc/aria2c.1.txt
2008-09-27 05:33:05 +00:00
Tatsuhiro Tsujikawa 16d725b96d 2008-09-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
When error occurred while aria2 was parsing an .aria2.conf file, 
print
	the usage of the option that caused error.
	* src/option_processing.cc
2008-09-27 04:54:15 +00:00
Tatsuhiro Tsujikawa e51e7207cf 2008-09-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Moved message of the error to OptionHandlerException.h
	* src/NameMatchOptionHandler.h
	* src/OptionHandlerException.h
2008-09-27 04:35:36 +00:00
Tatsuhiro Tsujikawa 54bb630077 2008-09-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
When error occurs while aria2 is parsing an command-line option, 
print
	the usage of the option.
	* src/Makefile.am
	* src/NameMatchOptionHandler.h
	* src/OptionHandlerException.h
	* src/option_processing.cc
2008-09-26 16:05:45 +00:00
Tatsuhiro Tsujikawa 87a5bb50c2 2008-09-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Reverted previous change.
	Insert username+'@' to URI(after ftp://) when URI is FTP scheme 
and
	username is not in URI.
	* src/HttpRequest.cc
	* src/Request.cc
	* test/HttpRequestTest.cc
	* test/RequestTest.cc
2008-09-25 16:06:29 +00:00
Tatsuhiro Tsujikawa 789e1926cb 2008-09-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Now colon is required for username and password in FTP URL, 
like:
	ftp://username:password@host.
	If colon is not there, aria2 don't parse it as a username. For 
example,
	aria2 don't retrieve username from ftp://username@host.
	This fix was made in order to login FTP server via 
non-transparent ftp
	proxy.
	* src/Request.cc
	* test/RequestTest.cc
2008-09-25 14:48:38 +00:00
Tatsuhiro Tsujikawa 92d702fa53 2008-09-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use netrc for HTTP.
	Now FTP user/password is sent in Authorization header when
	--ftp-via-http-proxy=get is given.
	* src/AuthConfigFactory.cc
	* src/HttpRequest.cc
	* src/HttpRequest.h
	* src/NetrcAuthResolver.cc
	* src/NetrcAuthResolver.h
	* src/OptionHandlerFactory.cc
	* src/option_processing.cc
	* src/prefs.cc
	* src/prefs.h
	* test/AuthConfigFactoryTest.cc
	* test/HttpRequestTest.cc
	* test/NetrcAuthResolverTest.cc
2008-09-25 14:37:28 +00:00
Tatsuhiro Tsujikawa 6bc233f414 2008-09-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Issue PWD command first and get working directory and use it as 
a prefix
	for CWD command.
	* src/DownloadEngine.cc
	* src/DownloadEngine.h
	* src/FtpConnection.cc
	* src/FtpConnection.h
	* src/FtpFinishDownloadCommand.cc
	* src/FtpInitiateConnectionCommand.cc
	* src/FtpNegotiationCommand.cc
	* src/FtpNegotiationCommand.h
	* test/FtpConnectionTest.cc
2008-09-24 17:01:57 +00:00
Tatsuhiro Tsujikawa d717ffb1d0 2008-09-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed default user/pass for FTP user/pass, since it should not 
have
	precedence over netrc configuration by default.
	* src/OptionHandlerFactory.cc
2008-09-24 17:00:01 +00:00
Tatsuhiro Tsujikawa dc6ef187b6 2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added debug log for socket event.
	* src/AbstractCommand.cc
	* src/PeerAbstractCommand.cc
2008-09-23 10:50:00 +00:00
Tatsuhiro Tsujikawa 2522175ff1 2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Log microseconds.
	* src/SimpleLogger.cc (SimpleLogger::writeLog)
2008-09-23 10:44:43 +00:00
Tatsuhiro Tsujikawa 2c6d2cd562 2008-09-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Replaced HelpItem.cc with OptionHandler.cc.
	* po/POTFILES.in
	
	Updated po files with 'make update-po'
	* po/aria2c.pot
	* po/*.po
2008-09-22 10:35:53 +00:00
Tatsuhiro Tsujikawa 7cceaa9340 2008-09-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed possible values from the text.
	* src/usage_text.h (TEXT_METALINK_PREFERRED_PROTOCOL)
2008-09-22 10:31:00 +00:00
Tatsuhiro Tsujikawa 77e095300b 2008-09-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed unused preferences:
	PREF_NO_PREALLOCATION
	PREF_STDOUT_LOG
	PREF_TRACKER_MAX_TRIES
	PREF_DIRECT_DOWNLOAD_TIMEOUT
	PREF_MIN_SEGMENT_SIZE
	* src/option_processing.cc
	* src/prefs.cc
	* src/prefs.h
2008-09-22 10:12:44 +00:00
Tatsuhiro Tsujikawa f66ed483fa 2008-09-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Integrated HelpItem into OptionParser to ease the workload for 
adding
	new options. Removed default value from usage text.
	* src/HelpItem.cc: Removed.
	* src/HelpItem.h: Removed.
	* src/HelpItemFactory.cc: Removed.
	* src/HelpItemFactory.h: Removed.
	* src/Makefile.am
	* src/Makefile.in
	* src/NameMatchOptionHandler.h
	* src/OptionHandler.cc
	* src/OptionHandler.h
	* src/OptionHandlerFactory.cc
	* src/OptionHandlerImpl.h
	* src/OptionParser.cc
	* src/OptionParser.h
	* src/TagContainer.cc: Removed.
	* src/TagContainer.h: Removed.
	* src/TaggedItem.cc: Removed.
	* src/TaggedItem.h: Removed.
	* src/main.cc
	* src/option_processing.cc
	* src/usage_text.h
	* src/version_usage.cc
	* test/HelpItemTest.cc: Removed.
	* test/Makefile.am
	* test/Makefile.in
	* test/OptionHandlerTest.cc
	* test/OptionParserTest.cc
	* test/TagContainerTest.cc: Removed.
2008-09-22 09:26:57 +00:00
Tatsuhiro Tsujikawa f6aaa094a8 2008-09-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Moved `TransferStat stat = ...' to inside the `if' clause.
	* src/RequestGroup.cc (RequestGroup::reportDownloadFinished)
2008-09-19 14:15:06 +00:00
Tatsuhiro Tsujikawa 67767e2f61 2008-09-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that a block in a piece is requested when same 
block is
	already requested to the same peer in end game mode.
	* src/BtRequestFactory.h
	* src/DefaultBtInteractive.cc
	* src/DefaultBtRequestFactory.cc
	* src/DefaultBtRequestFactory.h
	* src/DefaultPieceStorage.cc
	* src/DefaultPieceStorage.h
	* src/PieceStorage.h
	* src/UnknownLengthPieceStorage.cc
	* src/UnknownLengthPieceStorage.h
	* test/DefaultBtRequestFactoryTest.cc
	* test/DefaultPieceStorageTest.cc
	* test/MockBtRequestFactory.h
	* test/MockPieceStorage.h
2008-09-19 14:11:41 +00:00
Tatsuhiro Tsujikawa cdaafd8c8c 2008-09-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed _uploadLength and _downloadLength from 
PeerSessionResource
	and use PeerStat::_sessionUploadLength and
	PeerStat::_sessionDownloadLength.
	* src/PeerSessionResource.cc
	* src/PeerSessionResource.h
2008-09-19 13:57:18 +00:00
Tatsuhiro Tsujikawa c1ba5c9745 2008-09-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that prefixLength of split bucket which doesn't 
include
	local node ID is incremented.
	* src/DHTBucket.cc
	* src/DHTBucket.h
	* test/DHTBucketTest.cc
2008-09-18 13:21:33 +00:00
Tatsuhiro Tsujikawa e7d462bb39 2008-09-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added cookies.sqlite to EXTRA_DIST
	* test/Makefile.am
2008-09-17 13:37:32 +00:00
Tatsuhiro Tsujikawa 39317e85be 2008-09-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added Turkish translation. Updated French, German, Russian and
	Simplified Chinese translations. Thanks to all translators.
	* po/LINGUAS
	* po/de.po
	* po/fr.po
	* po/ru.po
	* po/tr.po
	* po/zh_CN.po
2008-09-17 12:51:33 +00:00
Tatsuhiro Tsujikawa 5a3a16f0b0 2008-09-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added deliminating text to the beginning of the log so that one 
can find
	where the log starts easily.
	* src/main.cc
2008-09-17 10:22:28 +00:00
Tatsuhiro Tsujikawa a1bac34778 2008-09-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Moved isProxyGETRequest function outside #ifdef ENABLE_ASYNC_DNS 
clause
	to fix compile error when async DNS is not enabled by 
configuration.
	* src/AbstractCommand.cc
2008-09-16 10:57:27 +00:00
Tatsuhiro Tsujikawa c921529d68 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
If establishing conneciton to a server is failed, then mark 
error on
	its ServerStat.
	Added the cause of error to log when error event occurred.
	Moved message string to message.h for translation.
	* src/AbstractCommand.cc
	* src/AbstractCommand.h
	* src/FtpNegotiationCommand.cc
	* src/HttpRequestCommand.cc
	* src/PeerAbstractCommand.cc
	* src/message.h
2008-09-14 14:31:19 +00:00
Tatsuhiro Tsujikawa 8687877139 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added the function to get error message from socket.
	* src/SocketCore.cc
	* src/SocketCore.h
2008-09-14 14:26:35 +00:00
Tatsuhiro Tsujikawa 72da43e47f 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added convenient method RequestGroupMan::getOrCreateServerStat()
	* src/RequestGroupMan.cc
	* src/RequestGroupMan.h
2008-09-14 14:25:16 +00:00
Tatsuhiro Tsujikawa 0680ac5e5e 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
If error event is received in epoll, then abort download 
immediately.
	* src/AbstractCommand.cc
	* src/Command.cc
	* src/Command.h
	* src/DownloadEngine.cc
	* src/PeerAbstractCommand.cc
2008-09-14 13:43:34 +00:00
Tatsuhiro Tsujikawa 81b2e6e108 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added usage message for --uri-selector, --server-stat-of,
	--server-stat-in, --server-stat-timeout options.
	* src/HelpItemFactory.cc
	* src/usage_text.h
2008-09-14 13:40:25 +00:00
Tatsuhiro Tsujikawa 479a16edd6 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added upper limit of FTP response buffer. The current 
implementation
	uses 4096bytes as a limit.
	* src/FtpConnection.cc
	* src/FtpConnection.h
	* test/FtpConnectionTest.cc
2008-09-14 12:51:30 +00:00
Tatsuhiro Tsujikawa 495f02ebbc 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use non-blocking socket for TCP communication to avoid possible
	blocking due to buffer full.
	* src/AbstractProxyRequestCommand.cc
	* src/FtpConnection.cc
	* src/FtpConnection.h
	* src/FtpNegotiationCommand.cc
	* src/FtpNegotiationCommand.h
	* src/HttpConnection.cc
	* src/HttpConnection.h
	* src/HttpRequestCommand.cc
	* src/InitiatorMSEHandshakeCommand.cc
	* src/InitiatorMSEHandshakeCommand.h
	* src/MSEHandshake.cc
	* src/MSEHandshake.h
	* src/Makefile.am
	* src/PeerConnection.cc
	* src/PeerConnection.h
	* src/PeerInteractionCommand.cc
	* src/PeerListenCommand.cc
	* src/ReceiverMSEHandshakeCommand.cc
	* src/ReceiverMSEHandshakeCommand.h
	* src/SocketBuffer.cc
	* src/SocketBuffer.h
	* src/SocketCore.cc
	* src/SocketCore.h
2008-09-13 16:32:47 +00:00
Tatsuhiro Tsujikawa 281319e8cd 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Call setStatusRealtime() in constructor.
	* src/RealtimeCommand.cc
	* src/RealtimeCommand.h
2008-09-13 15:57:23 +00:00
Tatsuhiro Tsujikawa 369aff31c2 2008-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Call Download::setNoWait(true) to execute newly created command 
without
	a pause.
	* src/AbstractCommand.cc
2008-09-13 15:54:52 +00:00
Tatsuhiro Tsujikawa 3599067ec1 2008-09-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added --max-file-not-found=NUM option. If aria2 receives `file 
not
	found' error from HTTP/FTP server NUM times without getting 
single
	bytes of data, then force the download to fail.
	Basically aria2 tris all URIs available. So if long list of URIs 
are
	specified in Metalink, then aria2 will take a long time to fail
	eventually if all URIs are outdated. This option eases this 
situation
	to limit the number of servers to try.
	* src/FtpNegotiationCommand.cc
	* src/HelpItemFactory.cc
	* src/HttpResponseCommand.cc
	* src/OptionHandlerFactory.cc
	* src/PeerStat.h
	* src/RequestGroup.cc
	* src/RequestGroup.h
	* src/SegmentMan.cc
	* src/SegmentMan.h
	* src/option_processing.cc
	* src/prefs.cc
	* src/prefs.h
	* src/usage_text.h
2008-09-10 14:56:44 +00:00
Tatsuhiro Tsujikawa 1b2a76706f 2008-09-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that bulkReceiveResponse() reads all received data 
as a
	response even if more than one response is in it.
	* src/FtpConnection.cc
	* src/FtpConnection.h
	* test/FtpConnectionTest.cc
2008-09-09 15:22:32 +00:00
Tatsuhiro Tsujikawa b23c3facc9 2008-09-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Merged from stable-0.15
	* m4/libcares.m4

	Use pkg-config
	* m4/sqlite3.m4
2008-09-09 12:49:11 +00:00
Tatsuhiro Tsujikawa 79597c32cc 2008-09-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed unnecessary if statement.
	* src/DefaultPieceStorage.cc (initPieceStorage)
2008-09-09 12:21:55 +00:00
Tatsuhiro Tsujikawa 4b997228ad 2008-09-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added --connect-timeout option to specify connect timeout in 
seconds.
	This option is in effect for HTTP/FTP/proxy server. The timeout 
for
	connecting to BitTorrent peer is not controlled by this option.
	* src/AbstractProxyRequestCommand.cc
	* src/FtpNegotiationCommand.cc
	* src/HelpItemFactory.cc
	* src/HttpRequestCommand.cc
	* src/OptionHandlerFactory.cc
	* src/option_processing.cc
	* src/prefs.cc
	* src/prefs.h
	* src/usage_text.h
2008-09-09 12:13:08 +00:00
Tatsuhiro Tsujikawa a91664cef8 2008-09-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added help message for -R option.
	* src/HelpItemFactory.cc
	* src/usage_text.h
2008-09-08 13:23:55 +00:00
Tatsuhiro Tsujikawa dc8915f599 2008-09-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added the message that the time is in local time zone.
	* src/RequestGroup.cc
2008-09-08 13:09:38 +00:00
Tatsuhiro Tsujikawa eb652b570e 2008-09-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Implemented the ability to get timestamp from remote FTP server 
using
	MDTM command described in RFC3659.
	* src/FtpConnection.cc
	* src/FtpConnection.h
	* src/FtpNegotiationCommand.cc
	* src/FtpNegotiationCommand.h
	* test/FtpConnectionTest.cc
	* test/Makefile.am
2008-09-08 13:06:44 +00:00
Tatsuhiro Tsujikawa dbc8f5b737 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Implemented the ability to get timestamp from remote HTTP server 
and
	apply it to local file. To enable this feature, --remote-time 
option
	is added. No usage text has been written yet.
	If several servers returns difference timestamp, then aria2 uses 
latest
	one.
	* src/CopyDiskAdaptor.cc
	* src/CopyDiskAdaptor.h
	* src/DirectDiskAdaptor.cc
	* src/DirectDiskAdaptor.h
	* src/DiskAdaptor.h
	* src/File.cc
	* src/File.h
	* src/HttpHeader.cc
	* src/HttpHeader.h
	* src/HttpResponse.cc
	* src/HttpResponse.h
	* src/HttpResponseCommand.cc
	* src/HttpResponseCommand.h
	* src/MultiDiskAdaptor.cc
	* src/MultiDiskAdaptor.h
	* src/OptionHandlerFactory.cc
	* src/RequestGroup.cc
	* src/RequestGroup.h
	* src/RequestGroupMan.cc
	* src/option_processing.cc
	* src/prefs.cc
	* src/prefs.h
	* test/CopyDiskAdaptorTest.cc
	* test/FileTest.cc
	* test/Makefile.am
	* test/Makefile.in
	* test/MultiDiskAdaptorTest.cc
	* test/TestUtil.cc
2008-09-07 14:38:26 +00:00
Tatsuhiro Tsujikawa 4e28efd925 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that DiskWriterEntry is not created when its
	FileEntry.isRequested() is false and it doesn't share a piece 
with
	other FileEntries that are requested. This bug causes 
segmentation fault
	in the end.
2008-09-07 11:37:15 +00:00
Tatsuhiro Tsujikawa 390538d0b5 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that exception is thrown when 
MultiDiskAdaptor::size() is
	called if the number of file entries are greater than max open 
files.
	* src/AbstractSingleDiskAdaptor.cc
	* src/AbstractSingleDiskAdaptor.h
	* src/DiskAdaptor.h
	* src/MultiDiskAdaptor.cc
	* src/MultiDiskAdaptor.h
	* test/MultiDiskAdaptorTest.cc
2008-09-07 08:29:09 +00:00
Tatsuhiro Tsujikawa 5fb94a3af0 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added a constuctor that receives struct timeval.
	Added operator<.
	* src/TimeA2.cc
	* src/TimeA2.h
	* test/TimeTest.cc
2008-09-07 04:57:31 +00:00
Tatsuhiro Tsujikawa b624a12ed0 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Parse `expires' of Set-Cookie using Time::parseHTTPDate()
	* src/CookieParser.cc
	* test/CookieParserTest.cc
	* test/HttpResponseTest.cc
2008-09-07 04:36:41 +00:00
Tatsuhiro Tsujikawa 69b18308d9 2008-09-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Implmented the functions to parse date.
	* src/TimeA2.cc
	* src/TimeA2.h
	* test/TimeTest.cc
2008-09-07 04:19:11 +00:00
Tatsuhiro Tsujikawa 9fc8b15736 2008-09-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added "Firefox3 Cookie" feature to FeatureConfig
	* src/FeatureConfig.cc
	* src/FeatureConfig.h
	* test/FeatureConfigTest.cc
2008-09-05 15:34:04 +00:00
Tatsuhiro Tsujikawa 40c1d08c5a 2008-09-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Bump up version number to 0.16.0b
	* configure.ac
2008-09-05 13:18:39 +00:00
Tatsuhiro Tsujikawa 8164c069d9 2008-09-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use pkg-config if is is available.
	* m4/openssl.m4
2008-09-03 14:44:57 +00:00