1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-12 13:01:09 +03:00

Comment out some code in os_unix.c that only runs on MacOSX with

SQLITE_ENABLE_LOCKING_STYLE.

FossilOrigin-Name: 4e50b0362ab6604a4b6c9f4ad849ec1733d6ce1a
This commit is contained in:
drh
2011-02-25 03:25:07 +00:00
parent 7f0857c437
commit 30f776fadb
3 changed files with 18 additions and 11 deletions

View File

@@ -1349,6 +1349,11 @@ static int _posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
** 4: [RRRR.]
*/
if( eFileLock==SHARED_LOCK ){
#if !defined(__APPLE__) || !SQLITE_ENABLE_LOCKING_STYLE
assert( handleNFSUnlock==0 );
#endif
#if defined(__APPLE__) && SQLITE_ENABLE_LOCKING_STYLE
if( handleNFSUnlock ){
off_t divSize = SHARED_SIZE - 1;
@@ -1388,7 +1393,9 @@ static int _posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
}
goto end_unlock;
}
}else{
}else
#endif /* defined(__APPLE__) && SQLITE_ENABLE_LOCKING_STYLE */
{
lock.l_type = F_RDLCK;
lock.l_whence = SEEK_SET;
lock.l_start = SHARED_FIRST;