aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-06-05 10:20:36 -0400
committerJack Lloyd <[email protected]>2019-06-05 10:20:36 -0400
commita3f402aba66c4fa07fef7d71b457f1a3c0709be7 (patch)
tree79c73963b9b6078d7a0019eb18233348332a6038 /src
parentda0ab423a62180ef5ac027a97c994b98075b25e9 (diff)
Lint fixes
Diffstat (limited to 'src')
-rwxr-xr-xsrc/python/botan2.py5
-rwxr-xr-xsrc/scripts/dist.py6
2 files changed, 6 insertions, 5 deletions
diff --git a/src/python/botan2.py b/src/python/botan2.py
index 66e7b9633..263bb8078 100755
--- a/src/python/botan2.py
+++ b/src/python/botan2.py
@@ -1248,7 +1248,8 @@ class X509Cert(object): # pylint: disable=invalid-name
raise BotanException("No filename or buf given")
if filename is not None and buf is not None:
raise BotanException("Both filename and buf given")
- elif filename is not None:
+
+ if filename is not None:
self.__obj = c_void_p(0)
_DLL.botan_x509_cert_load_file(byref(self.__obj), _ctype_str(filename))
elif buf is not None:
@@ -1416,7 +1417,7 @@ class MPI(object):
return r.value
def __hash__(self):
- return hash(to_bytes())
+ return hash(self.to_bytes())
def __eq__(self, other):
return self.cmp(other) == 0
diff --git a/src/scripts/dist.py b/src/scripts/dist.py
index 2de825adf..a43b2a468 100755
--- a/src/scripts/dist.py
+++ b/src/scripts/dist.py
@@ -47,9 +47,9 @@ def check_subprocess_results(subproc, name):
if stderr != '':
logging.error(stderr)
raise Exception('Running %s failed' % (name))
- else:
- if stderr != '':
- logging.warning(stderr)
+
+ if stderr != '':
+ logging.warning(stderr)
return raw_stdout