From 0a91abbc9f0db6b9ce89db5e640514c2b9a4ddfa Mon Sep 17 00:00:00 2001 From: Scott Kostyshak Date: Thu, 19 Nov 2015 00:18:40 -0500 Subject: [PATCH] Update exit code on second LaTeX run (#9765) Before, the exit code for the first LaTeX run was used to set the flag, which caused an error to be reported when in fact there was no error on the second run. This fix ammends 1dbf0e5a. --- src/LaTeX.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/LaTeX.cpp b/src/LaTeX.cpp index e6a185c6be..0949c69b7d 100644 --- a/src/LaTeX.cpp +++ b/src/LaTeX.cpp @@ -232,12 +232,12 @@ int LaTeX::run(TeXErrors & terr) LYXERR(Debug::LATEX, "Run #" << count); message(runMessage(count)); - int const exit_code = startscript(); + int exit_code = startscript(); scanres = scanLogFile(terr); if (scanres & ERROR_RERUN) { LYXERR(Debug::LATEX, "Rerunning LaTeX"); - startscript(); + exit_code = startscript(); scanres = scanLogFile(terr); } -- 2.39.5