update usage of debug-flag arguments

This commit is contained in:
Jacob Sword 2017-04-08 16:54:08 -04:00
parent dadbf7657f
commit 45dff6c0c8
2 changed files with 3 additions and 3 deletions

View File

@ -792,7 +792,7 @@ class Application(QApplication):
def exit(self, status):
"""Extend QApplication::exit to log the event."""
log.destroy.debug("Now calling QApplication::exit.")
if self._args.debug_exit:
if 'debug_exit' in self._args.debug_flags:
if hunter is None:
print("Not logging late shutdown because hunter could not be "
"imported!", file=sys.stderr)

View File

@ -207,10 +207,10 @@ class CrashHandler(QObject):
is_ignored_exception = (exctype is bdb.BdbQuit or
not issubclass(exctype, Exception))
if self._args.pdb_postmortem:
if 'pdb-postmortem' in self._args.debug_flags:
pdb.post_mortem(tb)
if is_ignored_exception or self._args.pdb_postmortem:
if is_ignored_exception or 'pdb-postmortem' in self._args.debug_flags:
# pdb exit, KeyboardInterrupt, ...
status = 0 if is_ignored_exception else 2
try: