/ Check-in [11a37a74]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fully release exclusive locks in the Unlock primitive of Unix. Ticket #913. (CVS 1993)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 11a37a74b101b9e37dcf1c3e57e45fbcd39a1c21
User & Date: drh 2004-10-01 03:02:48
Context
2004-10-01
14:38
Additional code to test the SQLITE_FULL return when the disk is full. (CVS 1994) check-in: 44e56f0b user: drh tags: trunk
03:02
Fully release exclusive locks in the Unlock primitive of Unix. Ticket #913. (CVS 1993) check-in: 11a37a74 user: drh tags: trunk
02:00
Use type i64 instead of off_t for file offsets since off_t is giving portability problems. Ticket #924. (CVS 1992) check-in: 8972c004 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/os_unix.c.

  1035   1035       return SQLITE_OK;
  1036   1036     }
  1037   1037     sqlite3OsEnterMutex();
  1038   1038     pLock = id->pLock;
  1039   1039     assert( pLock->cnt!=0 );
  1040   1040     if( id->locktype>SHARED_LOCK ){
  1041   1041       assert( pLock->locktype==id->locktype );
         1042  +    lock.l_type = F_RDLCK;
         1043  +    lock.l_whence = SEEK_SET;
         1044  +    lock.l_start = SHARED_FIRST;
         1045  +    lock.l_len = SHARED_SIZE;
         1046  +    fcntl(id->h, F_SETLK, &lock);
  1042   1047       lock.l_type = F_UNLCK;
  1043   1048       lock.l_whence = SEEK_SET;
  1044   1049       lock.l_start = PENDING_BYTE;
  1045   1050       lock.l_len = 2L;  assert( PENDING_BYTE+1==RESERVED_BYTE );
  1046   1051       fcntl(id->h, F_SETLK, &lock);
  1047   1052       pLock->locktype = SHARED_LOCK;
  1048   1053     }