]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fix compiler warnings on windows.
authordrh <drh@noemail.net>
Sat, 9 Jul 2016 16:38:25 +0000 (16:38 +0000)
committerdrh <drh@noemail.net>
Sat, 9 Jul 2016 16:38:25 +0000 (16:38 +0000)
FossilOrigin-Name: 8b22f777a11438ab0baadc7d9e471f415b734d1f

ext/misc/carray.c
ext/misc/csv.c
manifest
manifest.uuid
src/test_bestindex.c

index 70d226a85f885abb4c766706c8ff591b1cb5d9ac..b0c8be77d365497fcb20427e1301635201990f11 100644 (file)
@@ -303,7 +303,7 @@ static int carrayBestIndex(
     pIdxInfo->aConstraintUsage[cntIdx].argvIndex = 2;
     pIdxInfo->aConstraintUsage[cntIdx].omit = 1;
     pIdxInfo->estimatedCost = (double)1;
-    pIdxInfo->estimatedRows = (double)100;
+    pIdxInfo->estimatedRows = 100;
     pIdxInfo->idxNum = 2;
     if( ctypeIdx>=0 ){
       pIdxInfo->aConstraintUsage[ctypeIdx].argvIndex = 3;
@@ -312,7 +312,7 @@ static int carrayBestIndex(
     }
   }else{
     pIdxInfo->estimatedCost = (double)2147483647;
-    pIdxInfo->estimatedRows = (double)2147483647;
+    pIdxInfo->estimatedRows = 2147483647;
     pIdxInfo->idxNum = 0;
   }
   return SQLITE_OK;
index c0d8ecd3fc081bbd1cf43d100fb936cd959ef29d..3a7e32d3117bb7db517d8fc13a7feeda20054ae0 100644 (file)
@@ -375,7 +375,7 @@ static int csv_string_parameter(
   char **pzVal             /* Write the dequoted string value here */
 ){
   const char *zValue;
-  zValue = csv_parameter(zParam,strlen(zParam),zArg);
+  zValue = csv_parameter(zParam,(int)strlen(zParam),zArg);
   if( zValue==0 ) return 0;
   p->zErr[0] = 0;
   if( *pzVal ){
@@ -616,7 +616,7 @@ static int csvtabOpen(sqlite3_vtab *p, sqlite3_vtab_cursor **ppCursor){
   CsvCursor *pCur;
   size_t nByte;
   nByte = sizeof(*pCur) + (sizeof(char*)+sizeof(int))*pTab->nCol;
-  pCur = sqlite3_malloc( nByte );
+  pCur = sqlite3_malloc64( nByte );
   if( pCur==0 ) return SQLITE_NOMEM;
   memset(pCur, 0, nByte);
   pCur->azVal = (char**)&pCur[1];
@@ -647,7 +647,7 @@ static int csvtabNext(sqlite3_vtab_cursor *cur){
     }
     if( i<pTab->nCol ){
       if( pCur->aLen[i] < pCur->rdr.n+1 ){
-        char *zNew = sqlite3_realloc(pCur->azVal[i], pCur->rdr.n+1);
+        char *zNew = sqlite3_realloc64(pCur->azVal[i], pCur->rdr.n+1);
         if( zNew==0 ){
           csv_errmsg(&pCur->rdr, "out of memory");
           csv_xfer_error(pTab, &pCur->rdr);
index eef481b87d00478b510851af12f02c1a9c1d4bae..39562345496be43411de063b553fe1dbe9a4518c 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Fix\svarious\sinternal\s#defines\sto\sconform\sto\snew\sC-language\snaming\srestrictions,\nspecifically\sthat\sprivate-use\smacros\snames\smust\snot\sbegin\swith\s"_".
-D 2016-07-09T16:14:45.037
+C Fix\scompiler\swarnings\son\swindows.
+D 2016-07-09T16:38:25.217
 F Makefile.in 6c20d44f72d4564f11652b26291a214c8367e5db
 F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
 F Makefile.msc d66d0395c38571aab3804f8db0fa20707ae4609a
@@ -204,10 +204,10 @@ F ext/icu/README.txt d9fbbad0c2f647c3fdf715fc9fd64af53aedfc43
 F ext/icu/icu.c 43df9d8ef2fae7a325100ebd713ab089dc829dd7
 F ext/icu/sqliteicu.h 728867a802baa5a96de7495e9689a8e01715ef37
 F ext/misc/amatch.c 211108e201105e4bb0c076527b8cfd34330fc234
-F ext/misc/carray.c f1947c7d5bbce17f8244c9a05baae11d5d68467e
+F ext/misc/carray.c 29f3b2dbb93b93cedcc571660203d1e24d921bd3
 F ext/misc/closure.c 0d2a038df8fbae7f19de42e7c7d71f2e4dc88704
 F ext/misc/compress.c 122faa92d25033d6c3f07c39231de074ab3d2e83
-F ext/misc/csv.c f01126ba170fd4ef7c752b156568a80c912d4441
+F ext/misc/csv.c b92692b057707f5b7bb91feaedde790b2e38304e
 F ext/misc/eval.c f971962e92ebb8b0a4e6b62949463ee454d88fa2
 F ext/misc/fileio.c d4171c815d6543a9edef8308aab2951413cd8d0f
 F ext/misc/fuzzer.c 7c64b8197bb77b7d64eff7cac7848870235d4c25
@@ -405,7 +405,7 @@ F src/test9.c bea1e8cf52aa93695487badedd6e1886c321ea60
 F src/test_async.c 21e11293a2f72080eda70e1124e9102044531cd8
 F src/test_autoext.c dea8a01a7153b9adc97bd26161e4226329546e12
 F src/test_backup.c 2e6e6a081870150f20c526a2e9d0d29cda47d803
-F src/test_bestindex.c 29af3cc3b963ffe5760c85d142b9b3e5302c1e3d
+F src/test_bestindex.c f9e6807c52aa532e4775321ce3ed8e47c907ed45
 F src/test_blob.c b2551a9b5573232db5f66f292307c37067937239
 F src/test_btree.c 2e9978eca99a9a4bfa8cae949efb00886860a64f
 F src/test_config.c 7003f6f35134de6f19c6588f44783e43390ea277
@@ -1505,7 +1505,7 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
 F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
 F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
 F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
-P b5f32a896d0e4010ec67fcf1d635bb9aa797d3c2
-R 1420ae412f251bd23536749aacd8c4fa
+P 5471aca0158851d3fb0a2517306917536deb38bb
+R 51759f55d04de93087e3d229894a3277
 U drh
-Z e116500fbf8eef00f67c7f388726b705
+Z 7d1dfc3636ab19ed9a6789ae76c95a5f
index a0cf804e450dc6145bbe6a6d3cea096006807825..3c6dd362dc260355deee44c5d08a7f6b48003e98 100644 (file)
@@ -1 +1 @@
-5471aca0158851d3fb0a2517306917536deb38bb
\ No newline at end of file
+8b22f777a11438ab0baadc7d9e471f415b734d1f
\ No newline at end of file
index a955c2782c675cc3dcb1e052a237139cf6962767..f6f9d3eaf84da7ccba44aa21fb02eb82dc63e3eb 100644 (file)
@@ -179,8 +179,8 @@ static int tclConnect(
     return SQLITE_ERROR;
   }
 
-  zCmd = sqlite3_malloc(strlen(argv[3])+1);
-  pTab = (tcl_vtab*)sqlite3_malloc(sizeof(tcl_vtab));
+  zCmd = sqlite3_malloc64(strlen(argv[3])+1);
+  pTab = (tcl_vtab*)sqlite3_malloc64(sizeof(tcl_vtab));
   if( zCmd && pTab ){
     memcpy(zCmd, argv[3], strlen(argv[3])+1);
     tclDequote(zCmd);