]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
pytests: dns_base: remove a py2 compat thing
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Wed, 2 Dec 2020 22:57:48 +0000 (22:57 +0000)
committerJeremy Allison <jra@samba.org>
Wed, 17 Mar 2021 17:10:32 +0000 (17:10 +0000)
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
python/samba/tests/dns_base.py

index a5c7c5eb982ca498a231fa6a73088fb7fe270e95..5c0d6201b06364bfd91b106a878ada4959add3fe 100644 (file)
@@ -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)