aboutsummaryrefslogtreecommitdiff
path: root/src/markdown2pdf.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/markdown2pdf.hs')
-rw-r--r--src/markdown2pdf.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/markdown2pdf.hs b/src/markdown2pdf.hs
index faae544e7..4866b4163 100644
--- a/src/markdown2pdf.hs
+++ b/src/markdown2pdf.hs
@@ -119,7 +119,9 @@ checkLatex "" = (True, False, False, "Could not read log file")
checkLatex txt = (err , bib, ref, unlines $! msgs ++ tips)
where
xs `oneOf` x = any (flip isInfixOf x) xs
- msgs = filter (oneOf ["Error:", "Warning:"]) (lines txt)
+ msgs = dropWhile (not . errorline) $ lines txt
+ errorline ('!':_) = True
+ errorline _ = False
tips = checkPackages msgs
err = any (oneOf ["!", "LaTeX Error:", "Latex Error:"]) msgs
bib = any (oneOf ["Warning: Citation"