Skip to content
This repository has been archived by the owner on Sep 14, 2018. It is now read-only.

Commit

Permalink
Fix c#-sqlite build in release mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
jdhardy committed Jul 21, 2013
1 parent 97358c4 commit f3b3aed
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 8 additions & 0 deletions Languages/IronPython/IronPython.SQLite/c#sqlite/mutex_c.cs
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,14 @@ static bool sqlite3_mutex_held(sqlite3_mutex p){
static bool sqlite3_mutex_notheld(sqlite3_mutex p){
return p == null || sqlite3GlobalConfig.mutex.xMutexNotheld( p );
}
#else
static bool sqlite3_mutex_held(sqlite3_mutex p) {
return true;
}

static bool sqlite3_mutex_notheld(sqlite3_mutex p) {
return true;
}
#endif

#endif //* SQLITE_MUTEX_OMIT */
Expand Down
4 changes: 0 additions & 4 deletions Languages/IronPython/IronPython.SQLite/c#sqlite/mutex_w32.cs
Original file line number Diff line number Diff line change
Expand Up @@ -339,9 +339,7 @@ static void winMutexEnter( sqlite3_mutex p )

static int winMutexTry( sqlite3_mutex p )
{
#if !NDEBUG
DWORD tid = GetCurrentThreadId();
#endif
int rc = SQLITE_BUSY;
Debug.Assert( p.id == SQLITE_MUTEX_RECURSIVE || winMutexNotheld2( p, tid ) );
/*
Expand Down Expand Up @@ -381,9 +379,7 @@ static int winMutexTry( sqlite3_mutex p )
*/
static void winMutexLeave( sqlite3_mutex p )
{
#if !NDEBUG
DWORD tid = GetCurrentThreadId();
#endif
Debug.Assert( p.nRef > 0 );
Debug.Assert( p.owner == tid );
p.nRef--;
Expand Down

0 comments on commit f3b3aed

Please sign in to comment.