diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/avatarmanager.php | 2 | ||||
-rw-r--r-- | lib/private/preview/movie.php | 4 | ||||
-rw-r--r-- | lib/public/encryption/iencryptionmodule.php | 18 | ||||
-rw-r--r-- | lib/public/iavatarmanager.php | 2 |
4 files changed, 21 insertions, 5 deletions
diff --git a/lib/private/avatarmanager.php b/lib/private/avatarmanager.php index 21f88b1fd3f..b2d3e6eb3dd 100644 --- a/lib/private/avatarmanager.php +++ b/lib/private/avatarmanager.php @@ -27,6 +27,7 @@ namespace OC; use OCP\Files\Folder; +use OCP\Files\NotFoundException; use OCP\IAvatarManager; use OCP\IUserManager; use OCP\Files\IRootFolder; @@ -68,6 +69,7 @@ class AvatarManager implements IAvatarManager { * @param string $userId the ownCloud user id * @return \OCP\IAvatar * @throws \Exception In case the username is potentially dangerous + * @throws NotFoundException In case there is no user folder yet */ public function getAvatar($userId) { $user = $this->userManager->get($userId); diff --git a/lib/private/preview/movie.php b/lib/private/preview/movie.php index ee56f017229..43a8d674fc9 100644 --- a/lib/private/preview/movie.php +++ b/lib/private/preview/movie.php @@ -83,9 +83,9 @@ class Movie extends Provider { $tmpPath = \OC::$server->getTempManager()->getTemporaryFile(); if (self::$avconvBinary) { - $cmd = self::$avconvBinary . ' -an -y -ss ' . escapeshellarg($second) . + $cmd = self::$avconvBinary . ' -y -ss ' . escapeshellarg($second) . ' -i ' . escapeshellarg($absPath) . - ' -f mjpeg -vframes 1 -vsync 1 ' . escapeshellarg($tmpPath) . + ' -an -f mjpeg -vframes 1 -vsync 1 ' . escapeshellarg($tmpPath) . ' > /dev/null 2>&1'; } else { $cmd = self::$ffmpegBinary . ' -y -ss ' . escapeshellarg($second) . diff --git a/lib/public/encryption/iencryptionmodule.php b/lib/public/encryption/iencryptionmodule.php index 45e0b79c2a9..df30dd57cee 100644 --- a/lib/public/encryption/iencryptionmodule.php +++ b/lib/public/encryption/iencryptionmodule.php @@ -71,29 +71,41 @@ interface IEncryptionModule { * buffer. * * @param string $path to the file + * @param string $position id of the last block (looks like "<Number>end") + * * @return string remained data which should be written to the file in case * of a write operation + * * @since 8.1.0 + * @since 9.0.0 parameter $position added */ - public function end($path); + public function end($path, $position); /** * encrypt data * * @param string $data you want to encrypt + * @param string $position position of the block we want to encrypt (starts with '0') + * * @return mixed encrypted data + * * @since 8.1.0 + * @since 9.0.0 parameter $position added */ - public function encrypt($data); + public function encrypt($data, $position); /** * decrypt data * * @param string $data you want to decrypt + * @param string $position position of the block we want to decrypt + * * @return mixed decrypted data + * * @since 8.1.0 + * @since 9.0.0 parameter $position added */ - public function decrypt($data); + public function decrypt($data, $position); /** * update encrypted file, e.g. give additional users access to the file diff --git a/lib/public/iavatarmanager.php b/lib/public/iavatarmanager.php index 264c4fcf051..cb63ccaf6fd 100644 --- a/lib/public/iavatarmanager.php +++ b/lib/public/iavatarmanager.php @@ -36,6 +36,8 @@ interface IAvatarManager { * @see \OCP\IAvatar * @param string $user the ownCloud user id * @return \OCP\IAvatar + * @throws \Exception In case the username is potentially dangerous + * @throws \OCP\Files\NotFoundException In case there is no user folder yet * @since 6.0.0 */ public function getAvatar($user); |