diff options
author | blizzz <blizzz@arthur-schiwon.de> | 2022-06-21 18:44:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-21 18:44:05 +0200 |
commit | 2e10378052722c5affca71e60d926962be5d878c (patch) | |
tree | a302c3512b709ec303007577d488586521ae8d58 /lib | |
parent | 632d4d9a6e2baafb68bcc3c546d1ee0699c23e63 (diff) | |
parent | 8190441335aaa01baed01a3984c0a153126a5d0f (diff) | |
download | nextcloud-server-2e10378052722c5affca71e60d926962be5d878c.tar.gz nextcloud-server-2e10378052722c5affca71e60d926962be5d878c.zip |
Merge pull request #31475 from nextcloud/kofemann-patch-1
files: close open directory file descriptor on error path
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Storage/Common.php | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/private/Files/Storage/Common.php b/lib/private/Files/Storage/Common.php index 3c970ee75f5..a7bc44e10e2 100644 --- a/lib/private/Files/Storage/Common.php +++ b/lib/private/Files/Storage/Common.php @@ -228,6 +228,7 @@ abstract class Common implements Storage, ILockingStorage, IWriteStreamStorage { while ($file = readdir($dir)) { if (!Filesystem::isIgnoredDir($file)) { if (!$this->copy($path1 . '/' . $file, $path2 . '/' . $file)) { + closedir($dir); return false; } } |