Fix udp trackers being classified as DHT source

This commit is contained in:
Andrew Resch 2009-03-21 18:07:19 +00:00
parent c5cc5c283b
commit 850807ca43
1 changed files with 1 additions and 1 deletions

View File

@ -518,7 +518,7 @@ class Torrent:
tracker = self.trackers[0]["url"] tracker = self.trackers[0]["url"]
if tracker: if tracker:
url = urlparse(tracker) url = urlparse(tracker.replace("udp://", "http://"))
if hasattr(url, "hostname"): if hasattr(url, "hostname"):
host = (url.hostname or 'DHT') host = (url.hostname or 'DHT')
# Check if hostname is an IP address and just return it if that's the case # Check if hostname is an IP address and just return it if that's the case