mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
Merge pull request #31475 from nextcloud/kofemann-patch-1
files: close open directory file descriptor on error path
This commit is contained in:
commit
2e10378052
1 changed files with 1 additions and 0 deletions
|
|
@ -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;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue