Author: damoxc

Revision: 5787

Log:
        change the _libtorrent module so that the included libtorrent is 
checked for the correct version also (incase people have been following svn and 
the version requirement changes)

Diff:
Modified: trunk/deluge/_libtorrent.py
===================================================================
--- trunk/deluge/_libtorrent.py 2009-09-29 09:20:25 UTC (rev 5786)
+++ trunk/deluge/_libtorrent.py 2009-09-29 09:24:16 UTC (rev 5787)
@@ -47,10 +47,14 @@
 
 REQUIRED_VERSION = "0.14.5.0"
 
+def check_version(LT):
+    from deluge.common import VersionSplit
+    if VersionSplit(lt.version) < VersionSplit(REQUIRED_VERSION):
+        raise ImportError("This version of Deluge requires libtorrent >=%s!" % 
REQUIRED_VERSION)
+
 try:
     import deluge.libtorrent as lt
+    check_version(lt)
 except ImportError:
     import libtorrent as lt
-    from deluge.common import VersionSplit
-    if VersionSplit(lt.version) < VersionSplit(REQUIRED_VERSION):
-        raise ImportError("This version of Deluge requires libtorrent >=%s!" % 
REQUIRED_VERSION)
+    check_version(lt)
\ No newline at end of file



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"deluge-commit" 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-commit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to