]> git.ipfire.org Git - thirdparty/dnspython.git/commitdiff
fix zero padding on python3
authorBob Halley <halley@dnspython.org>
Tue, 15 Nov 2016 14:12:58 +0000 (06:12 -0800)
committerBob Halley <halley@dnspython.org>
Tue, 15 Nov 2016 14:12:58 +0000 (06:12 -0800)
dns/rdtypes/IN/APL.py

index 2bd4ce5a9e00938f935751159737f31057f50d0b..ac9c1f02bfa50d65078d539b3d2a31eb67e0fc74 100644 (file)
@@ -142,11 +142,11 @@ class APL(dns.rdata.Rdata):
             l = len(address)
             if header[0] == 1:
                 if l < 4:
-                    address += '\x00' * (4 - l)
+                    address += b'\x00' * (4 - l)
                 address = dns.inet.inet_ntop(dns.inet.AF_INET, address)
             elif header[0] == 2:
                 if l < 16:
-                    address += '\x00' * (16 - l)
+                    address += b'\x00' * (16 - l)
                 address = dns.inet.inet_ntop(dns.inet.AF_INET6, address)
             else:
                 #