Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/Files/ObjectStore/ObjectStoreStorage.php')
-rw-r--r--lib/private/Files/ObjectStore/ObjectStoreStorage.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/Files/ObjectStore/ObjectStoreStorage.php b/lib/private/Files/ObjectStore/ObjectStoreStorage.php
index 598dd4f80ae..5c792e59a3f 100644
--- a/lib/private/Files/ObjectStore/ObjectStoreStorage.php
+++ b/lib/private/Files/ObjectStore/ObjectStoreStorage.php
@@ -493,6 +493,9 @@ class ObjectStoreStorage extends \OC\Files\Storage\Common {
$stat['size'] = $size;
} else {
$this->objectStore->writeObject($urn, $stream, $mimetype);
+ if (is_resource($stream)) {
+ fclose($stream);
+ }
}
} catch (\Exception $ex) {
if (!$exists) {