Module: deluge Branch: master Commit: fce16ba51f12eca35a1cf4ed1956c02adba364b3
Author: John Garland <[email protected]> Date: Thu May 6 23:27:04 2010 +1000 Fix relative redirecting in blocklist plugin --- deluge/plugins/blocklist/blocklist/core.py | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/deluge/plugins/blocklist/blocklist/core.py b/deluge/plugins/blocklist/blocklist/core.py index db93069..f564b63 100644 --- a/deluge/plugins/blocklist/blocklist/core.py +++ b/deluge/plugins/blocklist/blocklist/core.py @@ -38,6 +38,7 @@ import os import time from datetime import datetime, timedelta from wsgiref.handlers import format_date_time +from urlparse import urljoin import shutil from twisted.internet.task import LoopingCall @@ -281,7 +282,7 @@ class Core(CorePluginBase): d = f if f.check(error.PageRedirect): # Handle redirect errors - location = error_msg.split(" to ")[1] + location = urljoin(self.config["url"], error_msg.split(" to ")[1]) if "Moved Permanently" in error_msg: log.debug("Setting blocklist url to %s", location) self.config["url"] = location -- 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.
