Physikerwelt has uploaded a new change for review. https://gerrit.wikimedia.org/r/258426
Change subject: Make math usable without RESTbase ...................................................................... Make math usable without RESTbase * Do not contact RESTbase in texvc rendering mode and use the well established tex checking that is already build into texvc. * Do not use RESTbase in LaTeXML mode. Bug: T121173 Change-Id: I1bd076b09206869b5ed75280d22e1b36bfb8d8ad --- M MathMathML.php M MathTexvc.php 2 files changed, 15 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Math refs/changes/26/258426/1 diff --git a/MathMathML.php b/MathMathML.php index dff9f41..58b9900 100644 --- a/MathMathML.php +++ b/MathMathML.php @@ -86,7 +86,7 @@ * @see MathRenderer::render() */ public function render( $forceReRendering = false ) { - if ( $this->inputType == 'tex' ) { + if ( $this->inputType == 'tex' && $this->mode == 'mathml' ) { $tex = $this->getTex(); $displaystyle = false; if ( $this->getMathStyle() == 'inlineDisplaystyle' ) { diff --git a/MathTexvc.php b/MathTexvc.php index eec8869..fae0576 100644 --- a/MathTexvc.php +++ b/MathTexvc.php @@ -465,4 +465,18 @@ public function setOutputHash( $hash ) { $this->hash = $hash; } + + /** + * Skip tex check for texvc rendering mode. + * Checking the tex code in texvc mode just adds a dependency to the + * texvccheck binary which does not improve security since the same + * checks are performed by texvc anyhow. Especially given the fact that + * texvccheck was derived from texvc. + * @return bool + */ + public function checkTex() { + return true; + } + + } -- To view, visit https://gerrit.wikimedia.org/r/258426 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I1bd076b09206869b5ed75280d22e1b36bfb8d8ad Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Math Gerrit-Branch: master Gerrit-Owner: Physikerwelt <w...@physikerwelt.de> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits