mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Simplification of the logic used to take the process-wide lock in the
unix-excl VFS. FossilOrigin-Name: 73defd52bb0e3e5db763d3bfbeebc972b645867e
This commit is contained in:
@@ -1406,9 +1406,7 @@ static int unixFileLock(unixFile *pFile, struct flock *pLock){
|
||||
unixInodeInfo *pInode = pFile->pInode;
|
||||
assert( unixMutexHeld() );
|
||||
assert( pInode!=0 );
|
||||
if( ((pFile->ctrlFlags & UNIXFILE_EXCL)!=0 || pInode->bProcessLock)
|
||||
&& ((pFile->ctrlFlags & UNIXFILE_RDONLY)==0)
|
||||
){
|
||||
if( (pFile->ctrlFlags & (UNIXFILE_EXCL|UNIXFILE_RDONLY))==UNIXFILE_EXCL ){
|
||||
if( pInode->bProcessLock==0 ){
|
||||
struct flock lock;
|
||||
assert( pInode->nLock==0 );
|
||||
|
||||
Reference in New Issue
Block a user