#2083: Deluge & libtorrent 0.16, can't add magnetlinks
------------------------+---------------------------------------------------
 Reporter:  DerFlob     |       Owner:       
     Type:  bug         |      Status:  new  
 Priority:  major       |   Milestone:       
Component:  libtorrent  |     Version:  1.3.5
 Keywords:              |  
------------------------+---------------------------------------------------

Comment(by arvid):

 I believe this patch to libtorrent fixes it. Could anyone confirm?

 {{{
 Index: bindings/python/src/session.cpp
 ===================================================================
 --- bindings/python/src/session.cpp     (revision 6789)
 +++ bindings/python/src/session.cpp     (working copy)
 @@ -153,7 +153,7 @@
          , std::vector<char>& rd, std::list<std::string>& string_storage)
      {
          // torrent_info objects are always held by an intrusive_ptr in
 the python binding
 -        if (params.has_key("ti"))
 +        if (params.has_key("ti") && !params.get("ti").is_none())
              p.ti = extract<intrusive_ptr<torrent_info> >(params["ti"]);

          if (params.has_key("info_hash"))
 }}}

 It's just a work-around for what appears to be Deluge passing in None as
 the ["tf"] field in the dict.

-- 
Ticket URL: <http://dev.deluge-torrent.org/ticket/2083#comment:3>
Deluge <http://deluge-torrent.org/>
Deluge project

-- 
You received this message because you are subscribed to the Google Groups 
"Deluge Dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/deluge-dev?hl=en.

Reply via email to