diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-03-19 11:09:36 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-03-19 11:09:36 -0700 |
commit | 3df75bc160827fbd0322ecf48e543977cda0156f (patch) | |
tree | c1a0a417011c6a82a863b7ef63896a2e0896b85e /pandoc.hs | |
parent | 575cc7eddcb903ca2edd4210be9b388c4c5af2e1 (diff) |
PDF: Changes to error reporting, to handle non-UTF8 error output.
Diffstat (limited to 'pandoc.hs')
-rw-r--r-- | pandoc.hs | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1172,7 +1172,10 @@ main = do res <- makePDF latexEngine f writerOptions doc2 case res of Right pdf -> writeBinary pdf - Left err' -> err 43 $ UTF8.toStringLazy err' + Left err' -> do + B.hPutStr stderr $ err' + B.hPut stderr $ B.pack [10] + err 43 "Error producing PDF from TeX source" | otherwise -> selfcontain (f writerOptions doc2 ++ ['\n' | not standalone']) >>= writerFn outputFile . handleEntities |