diff options
author | danielk1977 <danielk1977@noemail.net> | 2005-03-29 23:34:58 +0000 |
---|---|---|
committer | danielk1977 <danielk1977@noemail.net> | 2005-03-29 23:34:58 +0000 |
commit | 3eb8db90ba47b2b89f14e9edd5dbc84f586a1b51 (patch) | |
tree | 15328835c2a79609532db6b74f00a5d6feda2eda /src | |
parent | 60625c4c84639e271faea63668375bbcef5108d0 (diff) | |
download | sqlite-3eb8db90ba47b2b89f14e9edd5dbc84f586a1b51.tar.gz sqlite-3eb8db90ba47b2b89f14e9edd5dbc84f586a1b51.zip |
Fix a problem with threads and the global database list in main.c. (CVS 2434)
FossilOrigin-Name: 4aa05d2251b0cf6323ea695330de9ccf7e071bed
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c index 20335a01d..42a031c69 100644 --- a/src/main.c +++ b/src/main.c @@ -14,7 +14,7 @@ ** other files are for internal use by SQLite and should not be ** accessed by users of the library. ** -** $Id: main.c,v 1.284 2005/03/29 03:10:59 danielk1977 Exp $ +** $Id: main.c,v 1.285 2005/03/29 23:34:58 danielk1977 Exp $ */ #include "sqliteInt.h" #include "os.h" @@ -531,8 +531,9 @@ int sqlite3_close(sqlite3 *db){ #ifndef SQLITE_OMIT_GLOBALRECOVER { - sqlite3 *pPrev = pDbList; + sqlite3 *pPrev; sqlite3OsEnterMutex(); + pPrev = pDbList; while( pPrev && pPrev->pNext!=db ){ pPrev = pPrev->pNext; } |