mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
The sqlite3_vfs_register() interface now calls sqlite3_vfs_find(0) to make
sure the VFS subsystem is initialized. Ticket #2611. (CVS 4369) FossilOrigin-Name: 4a9999a36d01a8c6490792605a6f7e233cc4402c
This commit is contained in:
3
src/os.c
3
src/os.c
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/*
|
||||
** 2005 November 29
|
||||
**
|
||||
** The author disclaims copyright to this source code. In place of
|
||||
@@ -217,6 +217,7 @@ static void vfsUnlink(sqlite3_vfs *pVfs){
|
||||
*/
|
||||
int sqlite3_vfs_register(sqlite3_vfs *pVfs, int makeDflt){
|
||||
sqlite3_mutex *mutex = sqlite3_mutex_alloc(SQLITE_MUTEX_STATIC_MASTER);
|
||||
sqlite3_vfs_find(0); /* Make sure we are initialized */
|
||||
sqlite3_mutex_enter(mutex);
|
||||
vfsUnlink(pVfs);
|
||||
if( makeDflt || vfsList==0 ){
|
||||
|
Reference in New Issue
Block a user