Skip to content

Commit

Permalink
Use escapeshellcmd() instead of escapeshellarg() for PHP binary.
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianbergmann committed Jul 27, 2011
1 parent a68b29b commit 45d1f7e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion PHPUnit/Util/Fileloader.php
Expand Up @@ -127,7 +127,7 @@ protected static function syntaxCheck($filename)
$command = PHPUnit_Util_PHP::getPhpBinary();

if (DIRECTORY_SEPARATOR == '\\') {
$command = escapeshellarg($command);
$command = escapeshellcmd($command);
}

$command .= ' -l ' . escapeshellarg($filename);
Expand Down
2 changes: 1 addition & 1 deletion PHPUnit/Util/PHP.php
Expand Up @@ -109,7 +109,7 @@ public static function getPhpBinary()
if (!is_readable(self::$phpBinary)) {
self::$phpBinary = 'php';
} else {
self::$phpBinary = escapeshellarg(self::$phpBinary);
self::$phpBinary = escapeshellcmd(self::$phpBinary);
}
}

Expand Down

0 comments on commit 45d1f7e

Please sign in to comment.