Merging from stable

- Adding escapeshellarg to aspell path
This commit is contained in:
julmis 2005-08-25 07:49:39 +00:00
parent 8af1a3af3b
commit 1cefda4225

View file

@ -7,7 +7,7 @@ header('Content-type: text/html; charset=utf-8');
// Speller pages script http://spellerpages.sourceforge.net/ // Speller pages script http://spellerpages.sourceforge.net/
// Modified by Marc Alier on August 2004 for the integration with moodle // Modified by Marc Alier on August 2004 for the integration with moodle
$aspell_prog = $CFG->aspellpath; $aspell_prog = escapeshellarg($CFG->aspellpath);
$spellercss = $CFG->wwwroot .'/lib/speller/spellerStyle.css'; $spellercss = $CFG->wwwroot .'/lib/speller/spellerStyle.css';
$word_win_src = $CFG->wwwroot .'/lib/speller/wordWindow.js'; $word_win_src = $CFG->wwwroot .'/lib/speller/wordWindow.js';
@ -37,7 +37,7 @@ function check_language($cmd) {
$current_lang = current_language(); $current_lang = current_language();
$output = ''; $output = '';
if(!($handle = popen($cmd .' dump dicts', 'r'))) { if(!($handle = popen(escapeshellarg($cmd) .' dump dicts', 'r'))) {
error_handler("Couldn't create handle!"); error_handler("Couldn't create handle!");
exit; exit;
} }