Commit Graph

54 Commits

Author SHA1 Message Date
rakshasa 4d313e6353 Updated copyright information.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1301 e378c898-3ddf-0310-93e7-cc216c733640
2011-10-09 06:30:14 +00:00
rakshasa 156d69c854 * Added 'log.open_file' and 'log.add_output' options for using the new logging facilities.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1283 e378c898-3ddf-0310-93e7-cc216c733640
2011-09-21 02:38:05 +00:00
rakshasa c1eccb4bd7 * Fixed 'log.execute'.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1270 e378c898-3ddf-0310-93e7-cc216c733640
2011-08-17 04:30:23 +00:00
rakshasa f5d4924b22 * Casting printf input to match the format type.
* Properly clear the queued events during closing of a socket by checking for the file descriptor, not the ptr.

* SCGI m_task queue could overflow since the check was not working.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1246 e378c898-3ddf-0310-93e7-cc216c733640
2011-07-19 13:11:28 +00:00
rakshasa 1964ba5626 * Moved the default value for 'system.files.max_size' to rtorrent, and set the default in libtorrent to ~0.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1237 e378c898-3ddf-0310-93e7-cc216c733640
2011-06-14 03:12:33 +00:00
rakshasa 5200454cf7 * Added 'execute.*.bg' commands for non-blocking calls. Always returns 0.
* Added support for prioritizing first/last chunk of files matching specified patterns. Default:

  file.prioritize_toc.set=0
  file.prioritize_toc.first.set = {*.avi,*.mp4,*.mkv,*.gz}
  file.prioritize_toc.last.set  = {*.zip}


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1230 e378c898-3ddf-0310-93e7-cc216c733640
2011-05-21 16:04:05 +00:00
rakshasa 7d41393e5e * Added 'file.append' command for easy writing of stats to a log file.
* Cleaning up and prepearing the download / resource_manager for further improvements.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1214 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-22 09:12:17 +00:00
rakshasa 3aa7ed3000 * Added logging for hash queue size.
* Added missing headers for gcc-4.6.0.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1210 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-15 07:28:26 +00:00
rakshasa cb45e30aeb * Be more aggressive about freeing references to downloading / downloaded pieces when a peer connection sends choke or has an empty queue.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1208 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-12 04:08:33 +00:00
rakshasa 47efb608ab * Added more instrumentation.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1204 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-09 13:50:30 +00:00
rakshasa 6f71a8c1b1 * Added 'p.is_unwanted' and 'p.is_preferred' commands.
* Removed std::tr1:: in favor of std:: using namespace.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1202 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-07 08:41:16 +00:00
rakshasa 143de32dc4 * Added more logging facilities.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1195 e378c898-3ddf-0310-93e7-cc216c733640
2011-03-29 10:49:26 +00:00
rakshasa 5debd6f1be * Added better logging facilities.
* Changed tracker retry timers.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1192 e378c898-3ddf-0310-93e7-cc216c733640
2011-03-10 05:46:08 +00:00
rakshasa a0f3e95d20 * Fixed group commands.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1179 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-06 12:08:44 +00:00
rakshasa 49f61eeda3 * Added separate '-I' and '-K' switches, the former is for testing rtorrent code, the latter for webui's.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1178 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-05 23:49:06 +00:00
rakshasa 033e30af04 * Fixed more commands.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1177 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-05 03:36:14 +00:00
rakshasa 56e126d8a0 * Fixed more redirects to work properly with old webui's.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1175 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-03 10:47:36 +00:00
rakshasa 01738fd357 * Added some memory debugging utils.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1171 e378c898-3ddf-0310-93e7-cc216c733640
2010-08-19 10:30:42 +00:00
rakshasa 8b03988612 * Added 'rpc/fixed_key.h' header.
* Replaced Command with command_base.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1168 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-30 04:36:02 +00:00
rakshasa b530d35d94 * More work on rpc::object_storage and moving simple functions over to it.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1165 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-28 15:19:18 +00:00
rakshasa 9362453391 * Added a missing READ_PORT case to a switch in handshake.cc.
* Stuff.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1164 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-19 19:52:42 +00:00
rakshasa 575cafc7a8 * Old file/tracker related xmlrpc commands now work as before.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1163 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-12 03:37:07 +00:00
rakshasa 74bae32243 * Fixed more redirected commands.
* Cleaned up the Command stack implementation.

* Added framework for object_storage class that will hold variables and user-defined command lists.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1162 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-11 14:19:27 +00:00
rakshasa 4b9c4d5bbe * More cleanups of commands.
* Don't install the out-of-date man page.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1159 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-04 19:15:01 +00:00
rakshasa 4e4540e60f * Removed old Command classes.
* Redirects can now be made efficiently using rpc::CommandMap::create_redirect or "methods.redirect=new_key,dest_key".


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1155 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-28 18:09:09 +00:00
rakshasa 10f665e9c6 * Last of the commands converted, cleanup remaining.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1154 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-27 16:35:15 +00:00
rakshasa bc96dbfa2d * Modified the fallocate configure check so it will fail if 'fallocate' can't be found.
* Changed more commands to the new format.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1153 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-24 20:23:48 +00:00
rakshasa 83e993a1eb * Added missing command_new_slot.{cc,h} files.
* Converted more commands.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1150 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-21 09:45:45 +00:00
rakshasa ee5b0819a1 * Added 'system.files.{opened,closed,failed}_counter' commands.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1148 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-17 06:45:00 +00:00
rakshasa 44e77016a9 * Renamed 'system.method.*' to 'method.*'.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1139 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-03 13:45:34 +00:00
rakshasa 3cae3d37be * Cleaning up command names. The deprecated commands will be redirected.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1131 e378c898-3ddf-0310-93e7-cc216c733640
2010-02-16 17:29:53 +00:00
rakshasa 588f9e80c7 * Threaded XMLRPC support. Sponsored by Xirvik.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1123 e378c898-3ddf-0310-93e7-cc216c733640
2010-01-25 13:14:09 +00:00
rakshasa a60c330d3b * Logging for scgi calls.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1100 e378c898-3ddf-0310-93e7-cc216c733640
2009-10-27 15:11:32 +00:00
rakshasa 05d7028f61 * Added support for using posix_fallocate on newly resized files.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1090 e378c898-3ddf-0310-93e7-cc216c733640
2009-05-13 17:25:19 +00:00
rakshasa 3c670a7add * Add support for any number of custom download values identified by string keys.
d.set_custom=key,value
  d.get_custom=key (returns "" if not set)
  d.get_custom_throw=key (returns error if not set)

* With this patch, rtorrent will detect and complain about .torrent files with broken bencode representation (e.g. where the order of dictionary keys is not lexicographic).

* Choose a different poll type using the RTORRENT_POLL env. variable (if it's implemented), probably only useful as RTORRENT_POLL=select.

* Add the commands execute_capture and execute_capture_nothrow that work like their other counterparts but return the OUTPUT (stdout) of the given command.

  Note that the output is not modified in any way, in particular a trailing newline is NOT removed. To work around this, have the command write its output without it e.g. using echo -n. Also note that with execute_capture_nothrow there is no way to check if the command failed.

  Example usage: d.set_custom4=$execute_capture=handler.sh

* When logging peer communication errors, show IP and peer ID to help debugging.

All patches above by Josef Drexler.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1088 e378c898-3ddf-0310-93e7-cc216c733640
2009-05-13 09:39:00 +00:00
rakshasa de8a11c4fd * Added 'system.method.get', 'ui.current_view.set' and 'group.insert'
commands.

* Enabled different ratio settings for different groups of
downloads.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1079 e378c898-3ddf-0310-93e7-cc216c733640
2008-11-10 18:52:36 +00:00
rakshasa 5166253190 * Added 'argument.?' commands that passing of arguments to commands
created with 'system.method.insert'.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1077 e378c898-3ddf-0310-93e7-cc216c733640
2008-11-09 12:56:10 +00:00
rakshasa 49bb643cf3 * Added system.time{,_seconds,_usec} commands.
* Cleaned up XMLRPC handling and added support for empty targets so it
will handle print and cat properly.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1039 e378c898-3ddf-0310-93e7-cc216c733640
2008-02-22 14:11:40 +00:00
rakshasa 77a7d13b39 * Automatically prune the file status cache every day.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1025 e378c898-3ddf-0310-93e7-cc216c733640
2008-01-01 14:13:14 +00:00
rakshasa 3f644aed8f * Properly handle NULL ptr in target_any commands.
* Enable PEX by default.

* Renamed Download::start2/stop2.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1006 e378c898-3ddf-0310-93e7-cc216c733640
2007-11-10 16:34:37 +00:00
rakshasa 73c41074ec * Fix TextElement* to use rpc::target_type.
* Moved most of src/ui/download.cc to use commands for TextElements.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@967 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-30 16:33:52 +00:00
rakshasa 85d14f0e96 * Cleaned up the 'umask' command and renamed 'working_directory' to
'cwd'.

* Added 'd.{get,set}_custom[1-5]' for user scripts.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@963 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-23 21:21:11 +00:00
rakshasa ded9e12ff1 * Added 'get_pid', 'get/set_name' and 'cat' command.
* SocketFd::open_local() should use SOCK_STREAM, not SOCK_DGRAM.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@959 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-20 01:38:38 +00:00
rakshasa 5ec7790aa9 * Added 'd.get_hash' and 'get_hostname' commands.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@958 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-18 23:44:59 +00:00
rakshasa 788b496241 * Fix the use of strlcpy.
* Allow lists as arguments in commands by using '{' and '}'. The list
will be recursed and all '$' will be called, while '~' will only be
expanded when in the first element in the list. E.g "execute =
touch,{~/tmp/,$get_client_version=}"

* Added rak::path_expand that works on char buffers.

* Fixed RequestList::calculate_pipe_size so it doesn't request too
many pieces from fast peers.

* Added 'execute_log' for logging the result of calls to 'execute'.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@952 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-12 13:41:50 +00:00
rakshasa 781e1ca7dc * Add alternate execute_ commands.
* Fixed the queue size calculations.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@951 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-07 23:56:58 +00:00
rakshasa ef794b8eda * Added a default low_diskspace check for 500MB.
* Properly catch the exceptions being thrown by the 'in_*' events.

* Expand ~ in ExecFile.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@950 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-07 15:14:57 +00:00
rakshasa 37bc4c85c4 * Enabled 'max_downloads_div' by default.
* Added 'get_{client,library}_version' commands.

* Removed support for appending more than one command to 'schedule'.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@949 e378c898-3ddf-0310-93e7-cc216c733640
2007-08-03 11:56:18 +00:00
rakshasa 535db16850 * Bumping copyright year to 2007.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@938 e378c898-3ddf-0310-93e7-cc216c733640
2007-07-19 21:29:34 +00:00
rakshasa 350bdfde7e * Allow ';' as a separator for multi-command lines. Not recognized by
the string parser, so it must be preceeded by whitespace.

* Allow escaping of newlines in the resource file.

* Cleanup of the parse_command_* commands.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@936 e378c898-3ddf-0310-93e7-cc216c733640
2007-07-17 16:24:57 +00:00