broadcast_socket.hpp   broadcast_socket.hpp 
skipping to change at line 69 skipping to change at line 69
, unsigned char const* b2, int n); , unsigned char const* b2, int n);
TORRENT_EXPORT address guess_local_address(io_service&); TORRENT_EXPORT address guess_local_address(io_service&);
typedef boost::function<void(udp::endpoint const& from typedef boost::function<void(udp::endpoint const& from
, char* buffer, int size)> receive_handler_t; , char* buffer, int size)> receive_handler_t;
class TORRENT_EXTRA_EXPORT broadcast_socket class TORRENT_EXTRA_EXPORT broadcast_socket
{ {
public: public:
broadcast_socket(io_service& ios, udp::endpoint const& multi broadcast_socket(udp::endpoint const& multicast_endpoint
cast_endpoint , receive_handler_t const& handler);
, receive_handler_t const& handler, bool loopback =
true);
~broadcast_socket() { close(); } ~broadcast_socket() { close(); }
void open(io_service& ios, error_code& ec, bool loopback = t
rue);
enum flags_t { broadcast = 1 }; enum flags_t { broadcast = 1 };
void send(char const* buffer, int size, error_code& ec, int flags = 0); void send(char const* buffer, int size, error_code& ec, int flags = 0);
void close(); void close();
int num_send_sockets() const { return m_unicast_sockets.size (); } int num_send_sockets() const { return m_unicast_sockets.size (); }
void enable_ip_broadcast(bool e); void enable_ip_broadcast(bool e);
private: private:
struct socket_entry struct socket_entry
 End of changes. 2 change blocks. 
4 lines changed or deleted 5 lines changed or added


 error_code.hpp   error_code.hpp 
skipping to change at line 390 skipping to change at line 390
{ return boost::system::get_generic_category(); } { return boost::system::get_generic_category(); }
#else #else
{ return boost::system::generic_category(); } { return boost::system::generic_category(); }
#endif // BOOST_VERSION < 103600 #endif // BOOST_VERSION < 103600
#endif // BOOST_VERSION < 103500 #endif // BOOST_VERSION < 103500
#ifndef BOOST_NO_EXCEPTIONS #ifndef BOOST_NO_EXCEPTIONS
struct TORRENT_EXPORT libtorrent_exception: std::exception struct TORRENT_EXPORT libtorrent_exception: std::exception
{ {
libtorrent_exception(error_code const& s): m_error(s), m_msg (0) {} libtorrent_exception(error_code const& s): m_error(s), m_msg (0) {}
virtual const char* what() const throw() virtual const char* what() const throw();
{ virtual ~libtorrent_exception() throw();
if (!m_msg)
{
std::string msg = m_error.message();
m_msg = allocate_string_copy(msg.c_str());
}
return m_msg;
}
virtual ~libtorrent_exception() throw() { free(m_msg); }
error_code error() const { return m_error; } error_code error() const { return m_error; }
private: private:
error_code m_error; error_code m_error;
mutable char* m_msg; mutable char* m_msg;
}; };
#endif #endif
} }
#endif #endif
 End of changes. 1 change blocks. 
11 lines changed or deleted 2 lines changed or added


 lsd.hpp   lsd.hpp 
skipping to change at line 76 skipping to change at line 76
private: private:
void resend_announce(error_code const& e, std::string msg); void resend_announce(error_code const& e, std::string msg);
void on_announce(udp::endpoint const& from, char* buffer void on_announce(udp::endpoint const& from, char* buffer
, std::size_t bytes_transferred); , std::size_t bytes_transferred);
// void setup_receive(); // void setup_receive();
peer_callback_t m_callback; peer_callback_t m_callback;
// current retry count
int m_retry_count;
// the udp socket used to send and receive // the udp socket used to send and receive
// multicast messages on // multicast messages on
broadcast_socket m_socket; broadcast_socket m_socket;
// used to resend udp packets in case // used to resend udp packets in case
// they time out // they time out
deadline_timer m_broadcast_timer; deadline_timer m_broadcast_timer;
// current retry count
boost::uint32_t m_retry_count;
// this is a random (presumably unique)
// ID for this LSD node. It is used to
// ignore our own broadcast messages.
// There's no point in adding ourselves
// as a peer
int m_cookie;
bool m_disabled; bool m_disabled;
#if defined(TORRENT_LOGGING) || defined(TORRENT_VERBOSE_LOGGING) #if defined(TORRENT_LOGGING) || defined(TORRENT_VERBOSE_LOGGING)
std::ofstream m_log; FILE* m_log;
#endif #endif
}; };
} }
#endif #endif
 End of changes. 3 change blocks. 
4 lines changed or deleted 11 lines changed or added


 node_id.hpp   node_id.hpp 
skipping to change at line 61 skipping to change at line 61
// returns true if: distance(n1, ref) < distance(n2, ref) // returns true if: distance(n1, ref) < distance(n2, ref)
bool TORRENT_EXTRA_EXPORT compare_ref(node_id const& n1, node_id const& n2, node_id const& ref); bool TORRENT_EXTRA_EXPORT compare_ref(node_id const& n1, node_id const& n2, node_id const& ref);
// returns n in: 2^n <= distance(n1, n2) < 2^(n+1) // returns n in: 2^n <= distance(n1, n2) < 2^(n+1)
// usefult for finding out which bucket a node belongs to // usefult for finding out which bucket a node belongs to
int TORRENT_EXTRA_EXPORT distance_exp(node_id const& n1, node_id const& n2) ; int TORRENT_EXTRA_EXPORT distance_exp(node_id const& n1, node_id const& n2) ;
node_id TORRENT_EXTRA_EXPORT generate_id(address const& external_ip); node_id TORRENT_EXTRA_EXPORT generate_id(address const& external_ip);
node_id TORRENT_EXTRA_EXPORT generate_random_id(); node_id TORRENT_EXTRA_EXPORT generate_random_id();
node_id TORRENT_EXTRA_EXPORT generate_id_impl(address const& ip_, boost::ui nt32_t r);
bool TORRENT_EXTRA_EXPORT verify_id(node_id const& nid, address const& sour ce_ip); bool TORRENT_EXTRA_EXPORT verify_id(node_id const& nid, address const& sour ce_ip);
} } // namespace libtorrent::dht } } // namespace libtorrent::dht
#endif // NODE_ID_HPP #endif // NODE_ID_HPP
 End of changes. 1 change blocks. 
0 lines changed or deleted 1 lines changed or added


 session_impl.hpp   session_impl.hpp 
skipping to change at line 40 skipping to change at line 40
*/ */
#ifndef TORRENT_SESSION_IMPL_HPP_INCLUDED #ifndef TORRENT_SESSION_IMPL_HPP_INCLUDED
#define TORRENT_SESSION_IMPL_HPP_INCLUDED #define TORRENT_SESSION_IMPL_HPP_INCLUDED
#include <algorithm> #include <algorithm>
#include <vector> #include <vector>
#include <set> #include <set>
#include <list> #include <list>
#include <stdarg.h> // for va_start, va_end
#ifndef TORRENT_DISABLE_GEO_IP #ifndef TORRENT_DISABLE_GEO_IP
#ifdef WITH_SHIPPED_GEOIP_H #ifdef WITH_SHIPPED_GEOIP_H
#include "libtorrent/GeoIP.h" #include "libtorrent/GeoIP.h"
#else #else
#include <GeoIP.h> #include <GeoIP.h>
#endif #endif
#endif #endif
#ifdef _MSC_VER #ifdef _MSC_VER
skipping to change at line 736 skipping to change at line 737
boost::shared_ptr<socket_type> m_socks_listen_socket ; boost::shared_ptr<socket_type> m_socks_listen_socket ;
boost::uint16_t m_socks_listen_port; boost::uint16_t m_socks_listen_port;
void open_new_incoming_socks_connection(); void open_new_incoming_socks_connection();
#if TORRENT_USE_I2P #if TORRENT_USE_I2P
i2p_connection m_i2p_conn; i2p_connection m_i2p_conn;
boost::shared_ptr<socket_type> m_i2p_listen_socket; boost::shared_ptr<socket_type> m_i2p_listen_socket;
#endif #endif
void setup_listener(listen_socket_t* s, tcp::endpoin t ep, int retries void setup_listener(listen_socket_t* s, tcp::endpoin t ep, int& retries
, bool v6_only, int flags, error_code& ec); , bool v6_only, int flags, error_code& ec);
// the proxy used for bittorrent // the proxy used for bittorrent
proxy_settings m_proxy; proxy_settings m_proxy;
#ifndef TORRENT_DISABLE_DHT #ifndef TORRENT_DISABLE_DHT
entry m_dht_state; entry m_dht_state;
#endif #endif
// set to true when the session object // set to true when the session object
// is being destructed and the thread // is being destructed and the thread
 End of changes. 2 change blocks. 
1 lines changed or deleted 2 lines changed or added


 socket_type.hpp   socket_type.hpp 
skipping to change at line 304 skipping to change at line 304
#endif #endif
>::value >::value
}; };
size_type m_data[(storage_size + sizeof(size_type) - 1) / si zeof(size_type)]; size_type m_data[(storage_size + sizeof(size_type) - 1) / si zeof(size_type)];
}; };
// returns true if this socket is an SSL socket // returns true if this socket is an SSL socket
bool is_ssl(socket_type const& s); bool is_ssl(socket_type const& s);
// returns true if this is a uTP socket
bool is_utp(socket_type const& s);
// assuming the socket_type s is an ssl socket, make sure it // assuming the socket_type s is an ssl socket, make sure it
// verifies the hostname in its SSL handshake // verifies the hostname in its SSL handshake
void setup_ssl_hostname(socket_type& s, std::string const& hostname, error_code& ec); void setup_ssl_hostname(socket_type& s, std::string const& hostname, error_code& ec);
// properly shuts down SSL sockets. holder keeps s alive // properly shuts down SSL sockets. holder keeps s alive
void async_shutdown(socket_type& s, boost::shared_ptr<void> holder); void async_shutdown(socket_type& s, boost::shared_ptr<void> holder);
} }
#endif #endif
 End of changes. 1 change blocks. 
0 lines changed or deleted 3 lines changed or added


 torrent.hpp   torrent.hpp 
skipping to change at line 362 skipping to change at line 362
// -------------------------------------------- // --------------------------------------------
// PEER MANAGEMENT // PEER MANAGEMENT
#if defined TORRENT_VERBOSE_LOGGING || defined TORRENT_ERROR_LOGGING || def ined TORRENT_LOGGING #if defined TORRENT_VERBOSE_LOGGING || defined TORRENT_ERROR_LOGGING || def ined TORRENT_LOGGING
void log_to_all_peers(char const* message); void log_to_all_peers(char const* message);
#endif #endif
// add or remove a url that will be attempted for // add or remove a url that will be attempted for
// finding the file(s) in this torrent. // finding the file(s) in this torrent.
void add_web_seed(std::string const& url, web_seed_entry::ty void add_web_seed(std::string const& url, web_seed_entry::ty
pe_t type) pe_t type);
{
m_web_seeds.push_back(web_seed_entry(url, type));
}
void add_web_seed(std::string const& url, web_seed_entry::ty pe_t type void add_web_seed(std::string const& url, web_seed_entry::ty pe_t type
, std::string const& auth, web_seed_entry::headers_t , std::string const& auth, web_seed_entry::headers_t
const& extra_headers) const& extra_headers);
{
m_web_seeds.push_back(web_seed_entry(url, type, auth
, extra_headers));
}
void remove_web_seed(std::string const& url, web_seed_entry: :type_t type); void remove_web_seed(std::string const& url, web_seed_entry: :type_t type);
void disconnect_web_seed(peer_connection* p); void disconnect_web_seed(peer_connection* p);
void retry_web_seed(peer_connection* p, int retry = 0); void retry_web_seed(peer_connection* p, int retry = 0);
void remove_web_seed(peer_connection* p); void remove_web_seed(peer_connection* p);
std::list<web_seed_entry> web_seeds() const std::list<web_seed_entry> web_seeds() const
{ return m_web_seeds; } { return m_web_seeds; }
 End of changes. 2 change blocks. 
12 lines changed or deleted 4 lines changed or added


 tracker_manager.hpp   tracker_manager.hpp 
skipping to change at line 227 skipping to change at line 227
}; };
struct TORRENT_EXTRA_EXPORT tracker_connection struct TORRENT_EXTRA_EXPORT tracker_connection
: timeout_handler : timeout_handler
{ {
tracker_connection(tracker_manager& man tracker_connection(tracker_manager& man
, tracker_request const& req , tracker_request const& req
, io_service& ios , io_service& ios
, boost::weak_ptr<request_callback> r); , boost::weak_ptr<request_callback> r);
boost::shared_ptr<request_callback> requester(); boost::shared_ptr<request_callback> requester() const;
virtual ~tracker_connection() {} virtual ~tracker_connection() {}
tracker_request const& tracker_req() const { return m_req; } tracker_request const& tracker_req() const { return m_req; }
void fail_disp(error_code ec) { fail(ec); } void fail_disp(error_code ec) { fail(ec); }
void fail(error_code const& ec, int code = -1, char const* m sg = "" void fail(error_code const& ec, int code = -1, char const* m sg = ""
, int interval = 0, int min_interval = 0); , int interval = 0, int min_interval = 0);
virtual void start() = 0; virtual void start() = 0;
virtual void close(); virtual void close();
address const& bind_interface() const { return m_req.bind_ip ; } address const& bind_interface() const { return m_req.bind_ip ; }
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added


 udp_socket.hpp   udp_socket.hpp 
skipping to change at line 233 skipping to change at line 233
std::deque<queued_packet> m_queue; std::deque<queued_packet> m_queue;
// counts the number of outstanding async // counts the number of outstanding async
// operations hanging on this socket // operations hanging on this socket
int m_outstanding_ops; int m_outstanding_ops;
#if defined TORRENT_DEBUG || TORRENT_RELEASE_ASSERTS #if defined TORRENT_DEBUG || TORRENT_RELEASE_ASSERTS
bool m_started; bool m_started;
int m_magic; int m_magic;
int m_outstanding_when_aborted; int m_outstanding_when_aborted;
int m_outstanding_connect;
int m_outstanding_timeout;
int m_outstanding_resolve;
int m_outstanding_connect_queue;
int m_outstanding_socks;
#endif #endif
}; };
struct rate_limited_udp_socket : public udp_socket struct rate_limited_udp_socket : public udp_socket
{ {
rate_limited_udp_socket(io_service& ios, callback_t const& c , callback2_t const& c2, connection_queue& cc); rate_limited_udp_socket(io_service& ios, callback_t const& c , callback2_t const& c2, connection_queue& cc);
void set_rate_limit(int limit) { m_rate_limit = limit; } void set_rate_limit(int limit) { m_rate_limit = limit; }
bool can_send() const { return int(m_queue.size()) >= m_queu e_size_limit; } bool can_send() const { return int(m_queue.size()) >= m_queu e_size_limit; }
bool send(udp::endpoint const& ep, char const* p, int len, e rror_code& ec, int flags = 0); bool send(udp::endpoint const& ep, char const* p, int len, e rror_code& ec, int flags = 0);
void close(); void close();
 End of changes. 1 change blocks. 
0 lines changed or deleted 5 lines changed or added


 udp_tracker_connection.hpp   udp_tracker_connection.hpp 
skipping to change at line 111 skipping to change at line 111
void start_announce(); void start_announce();
bool on_receive(error_code const& e, udp::endpoint const& ep bool on_receive(error_code const& e, udp::endpoint const& ep
, char const* buf, int size); , char const* buf, int size);
bool on_receive_hostname(error_code const& e, char const* ho stname bool on_receive_hostname(error_code const& e, char const* ho stname
, char const* buf, int size); , char const* buf, int size);
bool on_connect_response(char const* buf, int size); bool on_connect_response(char const* buf, int size);
bool on_announce_response(char const* buf, int size); bool on_announce_response(char const* buf, int size);
bool on_scrape_response(char const* buf, int size); bool on_scrape_response(char const* buf, int size);
// wraps tracker_connection::fail
void fail(error_code const& ec, int code = -1
, char const* msg = "", int interval = 0, int min_in
terval = 0);
void send_udp_connect(); void send_udp_connect();
void send_udp_announce(); void send_udp_announce();
void send_udp_scrape(); void send_udp_scrape();
virtual void on_timeout(error_code const& ec); virtual void on_timeout(error_code const& ec);
udp::endpoint pick_target_endpoint() const;
// tracker_manager& m_man; // tracker_manager& m_man;
bool m_abort; bool m_abort;
std::string m_hostname; std::string m_hostname;
udp::endpoint m_target; udp::endpoint m_target;
std::list<tcp::endpoint> m_endpoints; std::list<tcp::endpoint> m_endpoints;
int m_transaction_id; int m_transaction_id;
aux::session_impl& m_ses; aux::session_impl& m_ses;
int m_attempts; int m_attempts;
 End of changes. 2 change blocks. 
0 lines changed or deleted 7 lines changed or added


 utp_socket_manager.hpp   utp_socket_manager.hpp 
skipping to change at line 62 skipping to change at line 62
utp_socket_manager(session_settings const& sett, udp_socket& s, incoming_utp_callback_t cb); utp_socket_manager(session_settings const& sett, udp_socket& s, incoming_utp_callback_t cb);
~utp_socket_manager(); ~utp_socket_manager();
void get_status(utp_status& s) const; void get_status(utp_status& s) const;
// return false if this is not a uTP packet // return false if this is not a uTP packet
bool incoming_packet(char const* p, int size, udp::endpoint const& ep); bool incoming_packet(char const* p, int size, udp::endpoint const& ep);
void tick(ptime now); void tick(ptime now);
tcp::endpoint local_endpoint(error_code& ec) const; tcp::endpoint local_endpoint(address const& remote, error_co
de& ec) const;
int local_port(error_code& ec) const;
// flags for send_packet // flags for send_packet
enum { dont_fragment = 1 }; enum { dont_fragment = 1 };
void send_packet(udp::endpoint const& ep, char const* p, int len void send_packet(udp::endpoint const& ep, char const* p, int len
, error_code& ec, int flags = 0); , error_code& ec, int flags = 0);
// internal, used by utp_stream // internal, used by utp_stream
void remove_socket(boost::uint16_t id); void remove_socket(boost::uint16_t id);
utp_socket_impl* new_utp_socket(utp_stream* str); utp_socket_impl* new_utp_socket(utp_stream* str);
 End of changes. 1 change blocks. 
1 lines changed or deleted 3 lines changed or added


 version.hpp   version.hpp 
skipping to change at line 38 skipping to change at line 38
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE. POSSIBILITY OF SUCH DAMAGE.
*/ */
#ifndef TORRENT_VERSION_HPP_INCLUDED #ifndef TORRENT_VERSION_HPP_INCLUDED
#define TORRENT_VERSION_HPP_INCLUDED #define TORRENT_VERSION_HPP_INCLUDED
#define LIBTORRENT_VERSION_MAJOR 0 #define LIBTORRENT_VERSION_MAJOR 0
#define LIBTORRENT_VERSION_MINOR 16 #define LIBTORRENT_VERSION_MINOR 16
#define LIBTORRENT_VERSION_TINY 4 #define LIBTORRENT_VERSION_TINY 5
// the format of this version is: MMmmtt // the format of this version is: MMmmtt
// M = Major version, m = minor version, t = tiny version // M = Major version, m = minor version, t = tiny version
#define LIBTORRENT_VERSION_NUM ((LIBTORRENT_VERSION_MAJOR * 10000) + (LIBTO RRENT_VERSION_MINOR * 100) + LIBTORRENT_VERSION_TINY) #define LIBTORRENT_VERSION_NUM ((LIBTORRENT_VERSION_MAJOR * 10000) + (LIBTO RRENT_VERSION_MINOR * 100) + LIBTORRENT_VERSION_TINY)
#define LIBTORRENT_VERSION "0.16.4.0" #define LIBTORRENT_VERSION "0.16.5.0"
#define LIBTORRENT_REVISION "$Rev: 7478 $" #define LIBTORRENT_REVISION "$Rev: 7607 $"
#endif #endif
 End of changes. 2 change blocks. 
3 lines changed or deleted 3 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/