diff options
Diffstat (limited to 'src/wrappers')
-rw-r--r-- | src/wrappers/markdown2pdf.in | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wrappers/markdown2pdf.in b/src/wrappers/markdown2pdf.in index 16df2b9cd..7bba44466 100644 --- a/src/wrappers/markdown2pdf.in +++ b/src/wrappers/markdown2pdf.in @@ -48,7 +48,8 @@ fi exit $errcode } if [ $runs -lt 3 ] && - grep -q "LaTeX Warning: There were undefined references." $texname.log; then + ((grep -q "LaTeX Warning: There were undefined references." $texname.log) || + (echo "$@" | grep -q -- "--toc")); then runs=$(($runs + 1)) if grep -q "LaTeX Warning:.*[Cc]itation" $texname.log; then bibtex $texname 2>&1 >bibtex.err |