Fix: command not found with escapeshellarg !

This commit is contained in:
Regis Houssin 2017-09-29 14:52:05 +02:00
parent abc86d72f6
commit 9490e13c21

View File

@ -160,7 +160,8 @@ class AntiVir
if (! preg_match('/%file/',$conf->global->MAIN_ANTIVIRUS_PARAM)) if (! preg_match('/%file/',$conf->global->MAIN_ANTIVIRUS_PARAM))
$param=$param." ".escapeshellarg(trim($file)); $param=$param." ".escapeshellarg(trim($file));
if (preg_match("/\s/",$command)) $command=escapeshellarg($command); // Use quotes on command. Using escapeshellcmd fails. //if (preg_match("/\s/",$command)) $command=escapeshellarg($command); // Use quotes on command. Using escapeshellcmd fails.
if (preg_match("/\s/",$command)) $command=escapeshellcmd($command); // Use quotes on command. Using escapeshellarg fails.
$ret=$command.' '.$param; $ret=$command.' '.$param;
//$ret=$command.' '.$param.' 2>&1'; //$ret=$command.' '.$param.' 2>&1';