summaryrefslogtreecommitdiff
path: root/asciidoc/asciidoc.py
diff options
context:
space:
mode:
Diffstat (limited to 'asciidoc/asciidoc.py')
-rw-r--r--asciidoc/asciidoc.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/asciidoc/asciidoc.py b/asciidoc/asciidoc.py
index bf54477..07b23f7 100644
--- a/asciidoc/asciidoc.py
+++ b/asciidoc/asciidoc.py
@@ -6259,12 +6259,12 @@ def asciidoc(backend, doctype, confiles, infile, outfile, options):
writer.close()
finally:
reader.closefile()
- except KeyboardInterrupt:
- raise
- except Exception as e:
+ except BaseException as e:
# Cleanup.
if outfile and outfile != '<stdout>' and os.path.isfile(outfile):
os.unlink(outfile)
+ if not isinstance(e, Exception):
+ raise
# Build and print error description.
msg = 'FAILED: '
if reader.cursor: