From: Alexandre Emsenhuber Date: Sat, 12 Sep 2009 10:19:56 +0000 (+0000) Subject: Use wfEscapeShellArg() so that the script works correctly when paths contain whitespaces X-Git-Tag: 1.31.0-rc.0~39773 X-Git-Url: http://git.cyclocoop.org/?a=commitdiff_plain;h=11b7e2842ba124fd162b3d0295e49217dfc4a1cc;p=lhc%2Fweb%2Fwiklou.git Use wfEscapeShellArg() so that the script works correctly when paths contain whitespaces --- diff --git a/maintenance/syntaxChecker.php b/maintenance/syntaxChecker.php index 387b92a684..90d1f878dc 100644 --- a/maintenance/syntaxChecker.php +++ b/maintenance/syntaxChecker.php @@ -125,7 +125,7 @@ class SyntaxChecker extends Maintenance { * @return boolean */ private function checkFileWithCli( $file ) { - $res = exec( 'php -l ' . $file ); + $res = exec( 'php -l ' . wfEscapeShellArg( $file ) ); if( strpos( $res, 'No syntax errors detected' ) === false ) { $this->mFailures[$file] = $res; $this->output( $res . "\n" );