mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-05 13:00:14 +01:00
* WebDAV: allow locking of not (yet) existing files to create them
- failed before as there are no write-rights for not existing files - now we check for not existing files the write rights of the parent directory
This commit is contained in:
parent
25fcf25bdb
commit
a654002f7b
@ -1304,7 +1304,8 @@ class egw_vfs extends vfs_stream_wrapper
|
|||||||
static function lock($path,&$token,&$timeout,&$owner,&$scope,&$type,$update=false,$check_writable=true)
|
static function lock($path,&$token,&$timeout,&$owner,&$scope,&$type,$update=false,$check_writable=true)
|
||||||
{
|
{
|
||||||
// we require write rights to lock/unlock a resource
|
// we require write rights to lock/unlock a resource
|
||||||
if (!$path || $update && !$token || $check_writable && !egw_vfs::is_writable($path))
|
if (!$path || $update && !$token || $check_writable &&
|
||||||
|
!(egw_vfs::is_writable($path) || !egw_vfs::file_exists($path) && egw_vfs::is_writable(egw_vfs::dirname($path))))
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user