From: Bob Halley Date: Fri, 10 Jan 2014 14:18:47 +0000 (-0800) Subject: Remove lingering ord()s from is_multicast() X-Git-Tag: v1.12.0-py3~24 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=5bb84b13364333fb4dabe1a9c9c7f464ceb20bf5;p=thirdparty%2Fdnspython.git Remove lingering ord()s from is_multicast() --- diff --git a/ChangeLog b/ChangeLog index 56aeb41b..51ea381d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-01-10 Bob Halley + + * dns/inet.py (is_multicast): Removed lingering ord()s. + 2013-12-11 Bob Halley * dns/query.py: Fix problems with the IXFR state machine which caused diff --git a/dns/inet.py b/dns/inet.py index 3b7e88f7..56a1bd7c 100644 --- a/dns/inet.py +++ b/dns/inet.py @@ -45,7 +45,7 @@ def inet_pton(family, text): implemented. @rtype: string """ - + if family == AF_INET: return dns.ipv4.inet_aton(text) elif family == AF_INET6: @@ -97,12 +97,11 @@ def is_multicast(text): @rtype: bool """ try: - first = ord(dns.ipv4.inet_aton(text)[0]) + first = dns.ipv4.inet_aton(text)[0] return (first >= 224 and first <= 239) except: try: - first = ord(dns.ipv6.inet_aton(text)[0]) + first = dns.ipv6.inet_aton(text)[0] return (first == 255) except: raise ValueError -