summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/cli/bitmask_cli.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/leap/bitmask/cli/bitmask_cli.py')
-rwxr-xr-xsrc/leap/bitmask/cli/bitmask_cli.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/leap/bitmask/cli/bitmask_cli.py b/src/leap/bitmask/cli/bitmask_cli.py
index f138e48..839b7f5 100755
--- a/src/leap/bitmask/cli/bitmask_cli.py
+++ b/src/leap/bitmask/cli/bitmask_cli.py
@@ -150,7 +150,7 @@ def execute():
errb=lambda: cli.start(args))
except Exception, e:
print (Fore.RED + "ERROR: " + Fore.RESET +
- "%s" % e.strerror)
+ "%s" % str(e))
defer.returnValue('')
cli.data = []
@@ -164,12 +164,10 @@ def execute():
if 'start' in sys.argv or 'restart' in sys.argv:
command.default_dict_printer({'start': 'ok'})
except Exception, e:
- if hasattr(e, 'strerror'):
- print (Fore.RED + "ERROR: " + Fore.RESET +
- "%s" % e.strerror)
- else:
- if not hasattr(e, 'expected'):
- print traceback.format_exc()
+ print(Fore.RED + "ERROR: " + Fore.RESET +
+ "%s" % str(e))
+ if not hasattr(e, 'expected'):
+ print(traceback.format_exc())
finally:
yield reactor.stop()