From defd700c45e8feaab8d53de470d5cf168fed7c19 Mon Sep 17 00:00:00 2001 From: Marcos Pinto Date: Wed, 23 May 2007 14:23:28 +0000 Subject: [PATCH] activate ut_pex and metadata from swarm --- src/deluge_core.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/deluge_core.cpp b/src/deluge_core.cpp index 545515eda..6079f16e1 100644 --- a/src/deluge_core.cpp +++ b/src/deluge_core.cpp @@ -53,6 +53,8 @@ #include "libtorrent/file_pool.hpp" #include "libtorrent/file.hpp" #include "libtorrent/torrent_info.hpp" +#include "libtorrent/extensions/metadata_transfer.hpp" +#include "libtorrent/extensions/ut_pex.hpp" using namespace boost::filesystem; using namespace libtorrent; @@ -325,6 +327,9 @@ static PyObject *torrent_init(PyObject *self, PyObject *args) M_ses->set_settings(*M_settings); M_ses->set_severity_level(alert::debug); + M_ses->add_extension(&libtorrent::create_metadata_plugin); + M_ses->add_extension(&libtorrent::create_ut_pex_plugin); + M_constants = Py_BuildValue("{s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i,s:i}", "EVENT_NULL", EVENT_NULL, "EVENT_FINISHED", EVENT_FINISHED,