escape $second + update PHPDoc

This commit is contained in:
Thomas Müller 2014-04-16 19:45:55 +02:00
parent d0f8cc20c5
commit a4389340b8
1 changed files with 7 additions and 7 deletions

View File

@ -65,11 +65,11 @@ if (!\OC_Util::runningOnWindows()) {
} }
/** /**
* @param $maxX * @param int $maxX
* @param $maxY * @param int $maxY
* @param $absPath * @param string $absPath
* @param $tmpPath * @param string $tmpPath
* @param $second * @param int $second
* @return bool|\OC_Image * @return bool|\OC_Image
*/ */
private function generateThumbNail($maxX, $maxY, $absPath, $second) private function generateThumbNail($maxX, $maxY, $absPath, $second)
@ -77,12 +77,12 @@ if (!\OC_Util::runningOnWindows()) {
$tmpPath = \OC_Helper::tmpFile(); $tmpPath = \OC_Helper::tmpFile();
if (self::$avconvBinary) { if (self::$avconvBinary) {
$cmd = self::$avconvBinary . ' -an -y -ss ' . $second . $cmd = self::$avconvBinary . ' -an -y -ss ' . escapeshellarg($second) .
' -i ' . escapeshellarg($absPath) . ' -i ' . escapeshellarg($absPath) .
' -f mjpeg -vframes 1 -vsync 1 ' . escapeshellarg($tmpPath) . ' -f mjpeg -vframes 1 -vsync 1 ' . escapeshellarg($tmpPath) .
' > /dev/null 2>&1'; ' > /dev/null 2>&1';
} else { } else {
$cmd = self::$ffmpegBinary . ' -y -ss ' .$second . $cmd = self::$ffmpegBinary . ' -y -ss ' . escapeshellarg($second) .
' -i ' . escapeshellarg($absPath) . ' -i ' . escapeshellarg($absPath) .
' -f mjpeg -vframes 1' . ' -f mjpeg -vframes 1' .
' -s ' . escapeshellarg($maxX) . 'x' . escapeshellarg($maxY) . ' -s ' . escapeshellarg($maxX) . 'x' . escapeshellarg($maxY) .