]> Cypherpunks.ru repositories - pyderasn.git/commitdiff
is comparison is slightly faster
authorSergey Matveev <stargrave@stargrave.org>
Tue, 11 Feb 2020 10:48:07 +0000 (13:48 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Tue, 11 Feb 2020 10:48:58 +0000 (13:48 +0300)
pyderasn.py

index 53e7abf245352eb8b610ef23d525f43f55213945..fcaa5a6cdcce2e4057305b5cc37f0c9ffa164913 100755 (executable)
@@ -5134,7 +5134,7 @@ def get_def_by_path(defines_by_path, sub_decode_path):
         if len(path) != len(sub_decode_path):
             continue
         for p1, p2 in zip(path, sub_decode_path):
-            if (p1 != any) and (p1 != p2):
+            if (not p1 is any) and (p1 != p2):
                 break
         else:
             return define