Return an error if LaTeX is unable to compile the file.

This commit is contained in:
Richard Heck 2014-03-19 12:42:57 -04:00
parent 54a534c81f
commit 64e0c5589c
2 changed files with 4 additions and 0 deletions

View File

@ -293,6 +293,8 @@ def legacy_conversion_step1(latex_file, dpi, output_format, fg_color, bg_color,
# Compile the latex file.
latex_status, latex_stdout = run_latex(latex, latex_file)
if latex_status:
return (latex_status, [])
if pdf_output:
return legacy_conversion_step3(latex_file, dpi, output_format, True, skipMetrics)

View File

@ -409,6 +409,8 @@ def main(argv):
# Compile the latex file.
latex_status, latex_stdout = run_latex(latex, latex_file, bibtex)
if latex_status:
return (latex_status, [])
# The dvi output file name
dvi_file = latex_file_re.sub(".dvi", latex_file)