mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-08 14:02:16 +03:00
Add NULL checks on all sqlite3_vfs_find(0) calls. This is not strictly
necessary. There are no vulnerabilities here. However, adding these checks avoids unnecessary static analyzer complaints. [forum:/forumpost/ce1193be15|Forum post ce1193be15]. FossilOrigin-Name: 272a15b9f418fb0b31a9808f7c42c20cf52318035ff98935d8e8519634357e8d
This commit is contained in:
@@ -861,7 +861,9 @@ end_deserialize:
|
||||
*/
|
||||
int sqlite3MemdbInit(void){
|
||||
sqlite3_vfs *pLower = sqlite3_vfs_find(0);
|
||||
unsigned int sz = pLower->szOsFile;
|
||||
unsigned int sz;
|
||||
if( NEVER(pLower==0) ) return SQLITE_ERROR;
|
||||
sz = pLower->szOsFile;
|
||||
memdb_vfs.pAppData = pLower;
|
||||
/* The following conditional can only be true when compiled for
|
||||
** Windows x86 and SQLITE_MAX_MMAP_SIZE=0. We always leave
|
||||
|
Reference in New Issue
Block a user