don't use shared_from_this for session_impl

This commit is contained in:
Arvid Norberg 2014-02-21 04:30:59 +00:00
parent 77136592c2
commit 63c6e495bd
3 changed files with 2 additions and 3 deletions

View File

@ -191,7 +191,6 @@ namespace libtorrent
, boost::noncopyable , boost::noncopyable
, initialize_timer , initialize_timer
, udp_socket_observer , udp_socket_observer
, boost::enable_shared_from_this<session_impl>
{ {
#if defined TORRENT_VERBOSE_LOGGING || defined TORRENT_LOGGING || defined TORRENT_ERROR_LOGGING #if defined TORRENT_VERBOSE_LOGGING || defined TORRENT_LOGGING || defined TORRENT_ERROR_LOGGING
// this needs to be destructed last, since other components may log // this needs to be destructed last, since other components may log

View File

@ -217,7 +217,7 @@ namespace libtorrent
{ return boost::shared_ptr<torrent_plugin>(); } { return boost::shared_ptr<torrent_plugin>(); }
// called when plugin is added to a session // called when plugin is added to a session
virtual void added(boost::weak_ptr<aux::session_impl>) {} virtual void added(aux::session_impl*) {}
// called when an alert is posted // called when an alert is posted
// alerts that are filtered are not // alerts that are filtered are not

View File

@ -1549,7 +1549,7 @@ namespace aux {
m_ses_extensions.push_back(ext); m_ses_extensions.push_back(ext);
m_alerts.add_extension(ext); m_alerts.add_extension(ext);
ext->added(shared_from_this()); ext->added(this);
} }
#endif #endif