Permalink
Browse files

MDL-33616 Maths filter: Addded --halt-on-error swtich for latex to st…

…op execution, if any error is encountered
  • Loading branch information...
1 parent 904673d commit 08d32575e1c7abdfbe1701ec57cd9c5c9d212868 @rajeshtaneja rajeshtaneja committed Jul 9, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 filter/tex/latex.php
  2. +1 −1 filter/tex/texdebug.php
View
2 filter/tex/latex.php
@@ -108,7 +108,7 @@ function render( $formula, $filename, $fontsize=12, $density=240, $background=''
fclose( $fh );
// run latex on document
- $command = "{$CFG->filter_tex_pathlatex} --interaction=nonstopmode $tex";
+ $command = "{$CFG->filter_tex_pathlatex} --interaction=nonstopmode --halt-on-error $tex";
chdir( $this->temp_dir );
if ($this->execute($command, $log)) { // It allways False on Windows
// return false;
View
2 filter/tex/texdebug.php
@@ -244,7 +244,7 @@ function TexOutput($expression, $graphic=false) {
chdir($latex->temp_dir);
// step 1: latex command
- $cmd = "$CFG->filter_tex_pathlatex --interaction=nonstopmode $tex";
+ $cmd = "$CFG->filter_tex_pathlatex --interaction=nonstopmode --halt-on-error $tex";
$output .= execute($cmd);
// step 2: dvips command

0 comments on commit 08d3257

Please sign in to comment.