Latest SQLite vs. Xcode's Analyze : 61 issues
Latest SQLite vs. Xcode's Analyze : 61 issues
- Subject: Latest SQLite vs. Xcode's Analyze : 61 issues
- From: Jerry Krinock <email@hidden>
- Date: Wed, 12 Sep 2012 14:33:33 -0700
I just performed an *Analyze* on the latest version of sqlite, version 3.7.14, downloaded from http://sqlite.org. 61 issues
were found. I've pasted in several representative issues below. I can understand what's going on with some of them, but as a practical matter, how should one deal with this?
Thanks,
Jerry Krinock
// Issue 1 **************************
static int sqlite3OsRandomness(sqlite3_vfs *pVfs, int nByte, char *zBufOut){
return pVfs->xRandomness(pVfs, nByte, zBufOut);
}
// Issue: Access to field 'xRandomness' results in a dereference of a null pointer (loaded from variable 'pVfs')
// Issue 2 **************************
PgHdr1 *pPage = 0;
if( pPage ){
unsigned int h = iKey % pCache->nHash;
// Issue: Division by 0
// Issue 3 **************************
static void ptrmapPut(BtShared *pBt, Pgno key, u8 eType, Pgno parent, int *pRC){
DbPage *pDbPage; /* The pointer map page */
...
rc = sqlite3PagerGet(pBt->pPager, iPtrmap, &pDbPage);
...
pPtrmap = (u8 *)sqlite3PagerGetData(pDbPage);
// Issue: Function call argument is an uninitialized value
// Issue 4 **************************
static int sqlite3AuthCheck(
Parse *pParse,
...
){
sqlite3 *db = pParse->db;
...
if( db->init.busy || IN_DECLARE_VTAB ){
// Issue: Dereference of null pointer
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden