mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
fix: Wrap filesystem LockedExceptions for holding the readable path
Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
parent
c995428431
commit
11c5bc6a2a
1 changed files with 3 additions and 0 deletions
|
|
@ -764,6 +764,7 @@ abstract class Common implements Storage, ILockingStorage, IWriteStreamStorage {
|
|||
try {
|
||||
$provider->acquireLock('files/' . md5($this->getId() . '::' . trim($path, '/')), $type, $this->getId() . '::' . $path);
|
||||
} catch (LockedException $e) {
|
||||
$e = new LockedException($e->getPath(), $e, $e->getExistingLock(), $path);
|
||||
if ($logger) {
|
||||
$logger->info($e->getMessage(), ['exception' => $e]);
|
||||
}
|
||||
|
|
@ -796,6 +797,7 @@ abstract class Common implements Storage, ILockingStorage, IWriteStreamStorage {
|
|||
try {
|
||||
$provider->releaseLock('files/' . md5($this->getId() . '::' . trim($path, '/')), $type);
|
||||
} catch (LockedException $e) {
|
||||
$e = new LockedException($e->getPath(), $e, $e->getExistingLock(), $path);
|
||||
if ($logger) {
|
||||
$logger->info($e->getMessage(), ['exception' => $e]);
|
||||
}
|
||||
|
|
@ -828,6 +830,7 @@ abstract class Common implements Storage, ILockingStorage, IWriteStreamStorage {
|
|||
try {
|
||||
$provider->changeLock('files/' . md5($this->getId() . '::' . trim($path, '/')), $type);
|
||||
} catch (LockedException $e) {
|
||||
$e = new LockedException($e->getPath(), $e, $e->getExistingLock(), $path);
|
||||
if ($logger) {
|
||||
$logger->info($e->getMessage(), ['exception' => $e]);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue