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

Strengthen the implementations of xShmMemoryBarrier on both the unix and

windows VFSes, so that they likely work even if SQLITE_THREADSAFE=0 is used.

FossilOrigin-Name: c6ab807b72ddfc1462f61aa91442b6fac04ace8a
This commit is contained in:
drh
2015-09-24 12:40:43 +00:00
parent c5de2d0a05
commit 22c733da64
4 changed files with 12 additions and 11 deletions

View File

@@ -4660,7 +4660,8 @@ static void unixShmBarrier(
sqlite3_file *fd /* Database file holding the shared memory */
){
UNUSED_PARAMETER(fd);
unixEnterMutex();
sqlite3MemoryBarrier(); /* compiler-defined memory barrier */
unixEnterMutex(); /* Also mutex, for redundancy */
unixLeaveMutex();
}