From: drh Date: Wed, 19 Jun 2013 13:59:49 +0000 (+0000) Subject: Additional compiler warning fixes. X-Git-Tag: version-3.8.0~134^2~5 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ad01d892a702ba66b578f512efa660680bc0d6bd;p=thirdparty%2Fsqlite.git Additional compiler warning fixes. FossilOrigin-Name: 8d2ae8e2f343f82f6fba6d0e89cee7f15b444aa3 --- diff --git a/manifest b/manifest index cb3eff1fbd..a1804c7bf0 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Fix\sa\sharmless\suninitialized\svariable\swarning. -D 2013-06-19T13:32:46.775 +C Additional\scompiler\swarning\sfixes. +D 2013-06-19T13:59:49.313 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f F Makefile.in 5e41da95d92656a5004b03d3576e8b226858a28e F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23 @@ -165,7 +165,7 @@ F src/btmutex.c 976f45a12e37293e32cae0281b15a21d48a8aaa7 F src/btree.c 7fba377c29573adfc6091832e27ee1fcbefb51d0 F src/btree.h 6fa8a3ff2483d0bb64a9f0105a8cedeac9e00cca F src/btreeInt.h eecc84f02375b2bb7a44abbcbbe3747dde73edb2 -F src/build.c eadda12ec0cae14dcdc13e97fd9a3fd2f02e9e8f +F src/build.c 42239cfd95533e4aacf4d58b4724c8f858de5ced F src/callback.c d7e46f40c3cf53c43550b7da7a1d0479910b62cc F src/complete.c dc1d136c0feee03c2f7550bafc0d29075e36deac F src/ctime.c 4262c227bc91cecc61ae37ed3a40f08069cfa267 @@ -289,7 +289,7 @@ F src/vtab.c b05e5f1f4902461ba9f5fc49bb7eb7c3a0741a83 F src/wal.c 436bfceb141b9423c45119e68e444358ee0ed35d F src/wal.h df01efe09c5cb8c8e391ff1715cca294f89668a4 F src/walker.c 4fa43583d0a84b48f93b1e88f11adf2065be4e73 -F src/where.c 0d12d709b410bc19e6a38dd48565d01aa2157a48 +F src/where.c 88884f3a0355ece00fa0d1a3566c4ed6fb5a8bed F test/8_3_names.test ebbb5cd36741350040fd28b432ceadf495be25b2 F test/aggerror.test a867e273ef9e3d7919f03ef4f0e8c0d2767944f2 F test/aggnested.test 45c0201e28045ad38a530b5a144b73cd4aa2cfd6 @@ -1096,7 +1096,7 @@ F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4 F tool/warnings.sh fbc018d67fd7395f440c28f33ef0f94420226381 F tool/wherecosttest.c f407dc4c79786982a475261866a161cd007947ae F tool/win/sqlite.vsix 97894c2790eda7b5bce3cc79cb2a8ec2fde9b3ac -P 8f27f35f288434b9e7bc503c608f1e2b590ade4d -R 5141bf3c3afc19733578e654fa12a0bb +P 9d3ef3bd2c6281784a537a22a87279f420649935 +R 576d65f25fc5d448aeaee421b4a0d4ef U drh -Z f8bc370f664ab6cce8282fa162fbfbcd +Z 2fbaa2eda000406e9f5d447a3a6c804c diff --git a/manifest.uuid b/manifest.uuid index c36b341294..350fdf4563 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -9d3ef3bd2c6281784a537a22a87279f420649935 \ No newline at end of file +8d2ae8e2f343f82f6fba6d0e89cee7f15b444aa3 \ No newline at end of file diff --git a/src/build.c b/src/build.c index 94fafff9fd..0a3922c952 100644 --- a/src/build.c +++ b/src/build.c @@ -3187,7 +3187,7 @@ SrcList *sqlite3SrcListEnlarge( } pSrc = pNew; nGot = (sqlite3DbMallocSize(db, pNew) - sizeof(*pSrc))/sizeof(pSrc->a[0])+1; - pSrc->nAlloc = (u16)nGot; + pSrc->nAlloc = (u8)nGot; } /* Move existing slots that come after the newly inserted slots @@ -3195,7 +3195,7 @@ SrcList *sqlite3SrcListEnlarge( for(i=pSrc->nSrc-1; i>=iStart; i--){ pSrc->a[i+nExtra] = pSrc->a[i]; } - pSrc->nSrc += (i16)nExtra; + pSrc->nSrc += (i8)nExtra; /* Zero the newly allocated slots */ memset(&pSrc->a[iStart], 0, sizeof(pSrc->a[0])*nExtra); diff --git a/src/where.c b/src/where.c index 7b7b071b41..f1cee90de1 100644 --- a/src/where.c +++ b/src/where.c @@ -883,7 +883,7 @@ WhereTerm *whereScanNext(WhereScan *pScan){ } } } - pWC = pScan->pWC = pScan->pWC->pOuter; + pScan->pWC = pScan->pWC->pOuter; k = 0; } pScan->pWC = pScan->pOrigWC; @@ -3433,7 +3433,6 @@ static Bitmask codeOneLoopStart( pIdx = pLoop->u.btree.pIndex; iIdxCur = pLevel->iIdxCur; - k = (nEq==pIdx->nColumn ? -1 : pIdx->aiColumn[nEq]); /* If this loop satisfies a sort order (pOrderBy) request that ** was passed to this function to implement a "SELECT min(x) ..." @@ -3687,7 +3686,7 @@ static Bitmask codeOneLoopStart( pOrTab = sqlite3StackAllocRaw(pParse->db, sizeof(*pOrTab)+ nNotReady*sizeof(pOrTab->a[0])); if( pOrTab==0 ) return notReady; - pOrTab->nAlloc = (i16)(nNotReady + 1); + pOrTab->nAlloc = (u8)(nNotReady + 1); pOrTab->nSrc = pOrTab->nAlloc; memcpy(pOrTab->a, pTabItem, sizeof(*pTabItem)); origSrc = pWInfo->pTabList->a; @@ -4346,7 +4345,7 @@ static int whereLoopAddBtreeIndex( && !ExprHasProperty(pTerm->pExpr, EP_xIsSelect) ){ rc = whereInScanEst(pParse, pProbe, pTerm->pExpr->x.pList, &nOut); } - pNew->nOut = whereCost(nOut); + if( rc==SQLITE_OK ) pNew->nOut = whereCost(nOut); } #endif if( (pNew->wsFlags & (WHERE_IDX_ONLY|WHERE_IPK))==0 ){