mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-30 14:07:59 +00:00
[master] address some python2/3 incompatibilities
This commit is contained in:
@@ -48,8 +48,7 @@ class dnskey:
|
||||
self.fromtuple(name, alg, keyid, keyttl)
|
||||
|
||||
self._dir = directory or os.path.dirname(key) or '.'
|
||||
key = os.path.basename(key)
|
||||
|
||||
key = os.path.basename(key).decode('ascii')
|
||||
(name, alg, keyid) = key.split('+')
|
||||
name = name[1:-1]
|
||||
alg = int(alg)
|
||||
|
@@ -102,7 +102,7 @@ class PolicyLex:
|
||||
|
||||
def __init__(self, **kwargs):
|
||||
for r in self.reserved:
|
||||
self.reserved_map[r.lower().translate(maketrans('_', '-'))] = r
|
||||
self.reserved_map[r.lower().translate(str.maketrans('_', '-'))] = r
|
||||
self.lexer = lex.lex(object=self, **kwargs)
|
||||
|
||||
def test(self, text):
|
||||
|
Reference in New Issue
Block a user