From 94d7378fa23583f7fd7aa92ace089443b27a5efe Mon Sep 17 00:00:00 2001 From: Douglas Bagnall Date: Wed, 2 Dec 2020 22:57:48 +0000 Subject: [PATCH] pytests: dns_base: remove a py2 compat thing Signed-off-by: Douglas Bagnall Reviewed-by: Jeremy Allison --- python/samba/tests/dns_base.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/python/samba/tests/dns_base.py b/python/samba/tests/dns_base.py index a5c7c5eb982..5c0d6201b06 100644 --- a/python/samba/tests/dns_base.py +++ b/python/samba/tests/dns_base.py @@ -298,10 +298,7 @@ class DNSTKeyTest(DNSTest): # so it can be modified response_packet_list = [x if isinstance(x, int) else ord(x) for x in response_packet] del response_packet_list[-tsig_record_len:] - if isinstance(response_packet_list[11], int): - response_packet_list[11] = 0 - else: - response_packet_list[11] = chr(0) + response_packet_list[11] = 0 # convert modified list (of string char or int) to str/bytes response_packet_wo_tsig = bytes(response_packet_list) -- 2.47.3