merged changes from RC_1_0
This commit is contained in:
parent
d30ae3dda8
commit
601f8c0476
|
@ -3,7 +3,7 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="generator" content="Docutils 0.11: http://docutils.sourceforge.net/" />
|
||||
<meta name="generator" content="Docutils 0.12: http://docutils.sourceforge.net/" />
|
||||
<title>Session</title>
|
||||
<meta name="author" content="Arvid Norberg, arvid@libtorrent.org" />
|
||||
<link rel="stylesheet" type="text/css" href="rst.css" />
|
||||
|
|
|
@ -1099,6 +1099,8 @@ triggered it
|
|||
|
||||
.. _disk.queued_disk_jobs:
|
||||
|
||||
.. _disk.num_running_disk_jobs:
|
||||
|
||||
.. _disk.num_read_jobs:
|
||||
|
||||
.. _disk.num_write_jobs:
|
||||
|
@ -1117,6 +1119,7 @@ triggered it
|
|||
<a name="disk.pinned_blocks"></a>
|
||||
<a name="disk.disk_blocks_in_use"></a>
|
||||
<a name="disk.queued_disk_jobs"></a>
|
||||
<a name="disk.num_running_disk_jobs"></a>
|
||||
<a name="disk.num_read_jobs"></a>
|
||||
<a name="disk.num_write_jobs"></a>
|
||||
<a name="disk.num_jobs"></a>
|
||||
|
@ -1124,29 +1127,31 @@ triggered it
|
|||
<a name="disk.num_running_threads"></a>
|
||||
<a name="disk.blocked_disk_jobs"></a>
|
||||
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| name | type |
|
||||
+==========================+=======+
|
||||
+============================+=======+
|
||||
| disk.request_latency | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.pinned_blocks | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.disk_blocks_in_use | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.queued_disk_jobs | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.num_running_disk_jobs | gauge |
|
||||
+----------------------------+-------+
|
||||
| disk.num_read_jobs | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.num_write_jobs | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.num_jobs | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.num_writing_threads | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.num_running_threads | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
| disk.blocked_disk_jobs | gauge |
|
||||
+--------------------------+-------+
|
||||
+----------------------------+-------+
|
||||
|
||||
|
||||
the number of microseconds it takes from receiving a request from a
|
||||
|
@ -1321,6 +1326,112 @@ hash a piece (when verifying against the piece hash)
|
|||
cumulative time spent in various disk jobs, as well
|
||||
as total for all disk jobs. Measured in microseconds
|
||||
|
||||
.. _disk.num_fenced_read:
|
||||
|
||||
.. _disk.num_fenced_write:
|
||||
|
||||
.. _disk.num_fenced_hash:
|
||||
|
||||
.. _disk.num_fenced_move_storage:
|
||||
|
||||
.. _disk.num_fenced_release_files:
|
||||
|
||||
.. _disk.num_fenced_delete_files:
|
||||
|
||||
.. _disk.num_fenced_check_fastresume:
|
||||
|
||||
.. _disk.num_fenced_save_resume_data:
|
||||
|
||||
.. _disk.num_fenced_rename_file:
|
||||
|
||||
.. _disk.num_fenced_stop_torrent:
|
||||
|
||||
.. _disk.num_fenced_cache_piece:
|
||||
|
||||
.. _disk.num_fenced_flush_piece:
|
||||
|
||||
.. _disk.num_fenced_flush_hashed:
|
||||
|
||||
.. _disk.num_fenced_flush_storage:
|
||||
|
||||
.. _disk.num_fenced_trim_cache:
|
||||
|
||||
.. _disk.num_fenced_file_priority:
|
||||
|
||||
.. _disk.num_fenced_load_torrent:
|
||||
|
||||
.. _disk.num_fenced_clear_piece:
|
||||
|
||||
.. _disk.num_fenced_tick_storage:
|
||||
|
||||
.. raw:: html
|
||||
|
||||
<a name="disk.num_fenced_read"></a>
|
||||
<a name="disk.num_fenced_write"></a>
|
||||
<a name="disk.num_fenced_hash"></a>
|
||||
<a name="disk.num_fenced_move_storage"></a>
|
||||
<a name="disk.num_fenced_release_files"></a>
|
||||
<a name="disk.num_fenced_delete_files"></a>
|
||||
<a name="disk.num_fenced_check_fastresume"></a>
|
||||
<a name="disk.num_fenced_save_resume_data"></a>
|
||||
<a name="disk.num_fenced_rename_file"></a>
|
||||
<a name="disk.num_fenced_stop_torrent"></a>
|
||||
<a name="disk.num_fenced_cache_piece"></a>
|
||||
<a name="disk.num_fenced_flush_piece"></a>
|
||||
<a name="disk.num_fenced_flush_hashed"></a>
|
||||
<a name="disk.num_fenced_flush_storage"></a>
|
||||
<a name="disk.num_fenced_trim_cache"></a>
|
||||
<a name="disk.num_fenced_file_priority"></a>
|
||||
<a name="disk.num_fenced_load_torrent"></a>
|
||||
<a name="disk.num_fenced_clear_piece"></a>
|
||||
<a name="disk.num_fenced_tick_storage"></a>
|
||||
|
||||
+----------------------------------+-------+
|
||||
| name | type |
|
||||
+==================================+=======+
|
||||
| disk.num_fenced_read | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_write | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_hash | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_move_storage | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_release_files | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_delete_files | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_check_fastresume | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_save_resume_data | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_rename_file | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_stop_torrent | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_cache_piece | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_flush_piece | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_flush_hashed | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_flush_storage | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_trim_cache | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_file_priority | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_load_torrent | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_clear_piece | gauge |
|
||||
+----------------------------------+-------+
|
||||
| disk.num_fenced_tick_storage | gauge |
|
||||
+----------------------------------+-------+
|
||||
|
||||
|
||||
for each kind of disk job, a counter of how many jobs of that kind
|
||||
are currently blocked by a disk fence
|
||||
|
||||
.. _dht.dht_nodes:
|
||||
|
||||
.. raw:: html
|
||||
|
|
|
@ -1771,19 +1771,21 @@ are missing in the bucket</h2><h4>../src/kademlia/node.cpp:486</h4><pre style="b
|
|||
return;
|
||||
}
|
||||
|
||||
node_entry const* ne = m_table.next_refresh();
|
||||
if (ne == NULL) return;
|
||||
|
||||
int bucket = 159 - distance_exp(m_id, ne->id);
|
||||
TORRENT_ASSERT(bucket < 160);
|
||||
send_single_refresh(ne->ep(), bucket, ne->id);
|
||||
}
|
||||
|
||||
void node_impl::send_single_refresh(udp::endpoint const& ep, int bucket
|
||||
, node_id const& id)
|
||||
{
|
||||
TORRENT_ASSERT(id != m_id);
|
||||
void* ptr = m_rpc.allocate_observer();
|
||||
if (ptr == 0) return;
|
||||
|
||||
TORRENT_ASSERT(bucket >= 0);
|
||||
TORRENT_ASSERT(bucket <= 159);
|
||||
|
||||
// generate a random node_id within the given bucket
|
||||
<div style="background: #ffff00" width="100%"> node_id mask = generate_prefix_mask(bucket + 1);
|
||||
</div> node_id target = generate_secret_id() & ~mask;
|
||||
|
@ -6632,7 +6634,13 @@ put completes</h2><h4>../src/kademlia/dht_tracker.cpp:430</h4><pre style="backgr
|
|||
#define TORRENT_USE_READV 0
|
||||
|
||||
#else
|
||||
#warning unknown OS, assuming BSD
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma message ( "unknown OS, assuming BSD" )
|
||||
#else
|
||||
#warning "unknown OS, assuming BSD"
|
||||
#endif
|
||||
|
||||
#define TORRENT_BSD
|
||||
#endif
|
||||
|
||||
|
@ -6670,13 +6678,16 @@ put completes</h2><h4>../src/kademlia/dht_tracker.cpp:430</h4><pre style="backgr
|
|||
// this is the maximum number of characters in a
|
||||
// path element / filename on windows
|
||||
#define TORRENT_MAX_PATH 255
|
||||
#warning unknown platform, assuming the longest path is 255
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma message ( "unknown platform, assuming the longest path is 255" )
|
||||
#else
|
||||
#warning "unknown platform, assuming the longest path is 255"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if defined TORRENT_WINDOWS && !defined TORRENT_MINGW
|
||||
|
||||
#include <stdarg.h>
|
||||
</pre></td></tr><tr style="background: #ccc"><td>relevance 0</td><td><a href="javascript:expand(62)">../include/libtorrent/peer_connection.hpp:725</a></td><td>make this private</td></tr><tr id="62" style="display: none;" colspan="3"><td colspan="3"><h2>make this private</h2><h4>../include/libtorrent/peer_connection.hpp:725</h4><pre style="background: #f6f6f6; border: solid 1px #ddd;"> void set_soft_packet_size(int size) { m_soft_packet_size = size; }
|
||||
|
||||
// internal
|
||||
</pre></td></tr><tr style="background: #ccc"><td>relevance 0</td><td><a href="javascript:expand(169)">../include/libtorrent/debug.hpp:215</a></td><td>rewrite this class to use FILE* instead and have a printf-like interface</td></tr><tr id="169" style="display: none;" colspan="3"><td colspan="3"><h2>rewrite this class to use FILE* instead and
|
||||
|
@ -7421,6 +7432,7 @@ namespace libtorrent
|
|||
TORRENT_EXPORT boost::system::error_code make_error_code(error_code_enum e);
|
||||
}
|
||||
|
||||
// the boost.system error category for UPnP errors
|
||||
TORRENT_EXPORT boost::system::error_category& get_upnp_category();
|
||||
|
||||
// int: port-mapping index
|
||||
|
|
|
@ -102,12 +102,15 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
namespace libtorrent
|
||||
{
|
||||
|
||||
#ifndef TORRENT_NO_DEPRECATE
|
||||
// thrown by bdecode() if the provided bencoded buffer does not contain
|
||||
// valid encoding.
|
||||
struct TORRENT_EXPORT invalid_encoding: std::exception
|
||||
{
|
||||
// hidden
|
||||
virtual const char* what() const throw() { return "invalid bencoding"; }
|
||||
};
|
||||
#endif
|
||||
|
||||
namespace detail
|
||||
{
|
||||
|
@ -429,7 +432,7 @@ namespace libtorrent
|
|||
// Now we just need to know how to retrieve information from the entry.
|
||||
//
|
||||
// If ``bdecode()`` encounters invalid encoded data in the range given to it
|
||||
// it will throw libtorrent_exception.
|
||||
// it will return a default constructed ``entry`` object.
|
||||
template<class OutIt> int bencode(OutIt out, const entry& e)
|
||||
{
|
||||
return detail::bencode_recursive(out, e);
|
||||
|
|
|
@ -83,6 +83,7 @@ namespace libtorrent
|
|||
// of the entry object.
|
||||
struct TORRENT_EXPORT type_error: std::runtime_error
|
||||
{
|
||||
// internal
|
||||
type_error(const char* error): std::runtime_error(error) {}
|
||||
};
|
||||
|
||||
|
|
|
@ -64,7 +64,9 @@ namespace socks_error {
|
|||
num_errors
|
||||
};
|
||||
|
||||
// internal
|
||||
TORRENT_EXPORT boost::system::error_code make_error_code(socks_error_code e);
|
||||
|
||||
} // namespace socks_error
|
||||
|
||||
// returns the error_category for SOCKS5 errors
|
||||
|
|
|
@ -408,6 +408,7 @@ namespace libtorrent
|
|||
// hidden
|
||||
~default_storage();
|
||||
|
||||
// hidden
|
||||
void set_file_priority(std::vector<boost::uint8_t> const& prio);
|
||||
#ifndef TORRENT_NO_DEPRECATE
|
||||
void finalize_file(int file, storage_error& ec);
|
||||
|
|
|
@ -97,6 +97,7 @@ namespace libtorrent
|
|||
TORRENT_EXPORT boost::system::error_code make_error_code(error_code_enum e);
|
||||
}
|
||||
|
||||
// the boost.system error category for UPnP errors
|
||||
TORRENT_EXPORT boost::system::error_category& get_upnp_category();
|
||||
|
||||
// int: port-mapping index
|
||||
|
|
|
@ -93,6 +93,8 @@ namespace libtorrent
|
|||
// in paths
|
||||
TORRENT_EXTRA_EXPORT bool verify_encoding(std::string& target, bool fix_paths = false)
|
||||
{
|
||||
if (target.empty()) return true;
|
||||
|
||||
std::string tmp_path;
|
||||
tmp_path.reserve(target.size()+5);
|
||||
bool valid_encoding = true;
|
||||
|
|
Loading…
Reference in New Issue