diff options
author | 2024-06-22 09:59:29 +0000 | |
---|---|---|
committer | 2024-06-22 11:59:29 +0200 | |
commit | 15e0bf6e5a57e60edf4a576db2dcb9bc07a163bf (patch) | |
tree | 1e12f30d28c8a9640121b16b526a817486ed17f2 /vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go | |
parent | update remaining gruf libraries relying on linkname (#3028) (diff) | |
download | gotosocial-15e0bf6e5a57e60edf4a576db2dcb9bc07a163bf.tar.xz |
[chore] update github.com/ncruces/go-sqlite3 -> v0.16.3 (#3029)
Diffstat (limited to 'vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go')
-rw-r--r-- | vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go b/vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go index 8c2abee81..ffeb3e0a0 100644 --- a/vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go +++ b/vendor/github.com/ncruces/go-sqlite3/vfs/shm_bsd.go @@ -128,10 +128,11 @@ func (s *vfsShm) shmOpen() (rc _ErrorCode) { } // Lock and truncate the file, if not readonly. + // The lock is only released by closing the file. if s.readOnly { rc = _READONLY_CANTINIT } else { - if rc := osWriteLock(f, 0, 0, 0); rc != _OK { + if rc := osLock(f, unix.LOCK_EX|unix.LOCK_NB, _IOERR_LOCK); rc != _OK { return rc } if err := f.Truncate(0); err != nil { |