1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-10 01:02:56 +03:00

Use sqlite3_mutex_notheld() instead of !sqlite3_mutex_held() inside

of assert() statements since the former works when mutexing is disabled
while the latter does not.

FossilOrigin-Name: 2211486b69cf53f5efb1334aff8b403b26596102
This commit is contained in:
drh
2010-09-02 17:15:19 +00:00
parent aac1bf9497
commit 1ff6e3ab89
3 changed files with 19 additions and 9 deletions

View File

@@ -365,7 +365,7 @@ void *sqlite3ScratchMalloc(int n){
}
sqlite3MemdebugSetType(p, MEMTYPE_SCRATCH);
}
assert( !sqlite3_mutex_held(mem0.mutex) );
assert( sqlite3_mutex_notheld(mem0.mutex) );
#if SQLITE_THREADSAFE==0 && !defined(NDEBUG)