/ Check-in [70262463]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix harmless compiler warnings previously seen in 64-bit MSVC builds.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 7026246300392a83cc23817dbc54c2c66bf1f2b3
User & Date: drh 2016-02-15 18:47:26
Context
2016-02-15
18:58
In the tool/warning.sh script, disable Android-specific compiler warning tests when not running on Linux. check-in: 153f01a8 user: drh tags: trunk
18:47
Fix harmless compiler warnings previously seen in 64-bit MSVC builds. check-in: 70262463 user: drh tags: trunk
18:15
Add the SQLITE_NOMEM_BKPT macro to enhance the ability to debug OOM errors. Only effective with compiling with SQLITE_DEBUG. check-in: 9b345476 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/test_fs.c.

   492    492     int nPrefix;
   493    493     const char *zDir;
   494    494     int nDir;
   495    495     char aWild[2] = { '\0', '\0' };
   496    496   
   497    497   #if SQLITE_OS_WIN
   498    498     zRoot = sqlite3_mprintf("%s%c", getenv("SystemDrive"), '/');
   499         -  nRoot = strlen(zRoot);
          499  +  nRoot = sqlite3Strlen30(zRoot);
   500    500     zPrefix = sqlite3_mprintf("%s", getenv("SystemDrive"));
   501         -  nPrefix = strlen(zPrefix);
          501  +  nPrefix = sqlite3Strlen30(zPrefix);
   502    502   #else
   503    503     zRoot = "/";
   504    504     nRoot = 1;
   505    505     zPrefix = "";
   506    506     nPrefix = 0;
   507    507   #endif
   508    508   

Changes to test/fuzzcheck.c.

   251    251     VFile *pNew = findVFile(zName);
   252    252     int i;
   253    253     if( pNew ) return pNew;
   254    254     for(i=0; i<MX_FILE && g.aFile[i].sz>=0; i++){}
   255    255     if( i>=MX_FILE ) return 0;
   256    256     pNew = &g.aFile[i];
   257    257     if( zName ){
   258         -    pNew->zFilename = safe_realloc(0, strlen(zName)+1);
   259         -    memcpy(pNew->zFilename, zName, strlen(zName)+1);
          258  +    int nName = (int)strlen(zName)+1;
          259  +    pNew->zFilename = safe_realloc(0, nName);
          260  +    memcpy(pNew->zFilename, zName, nName);
   260    261     }else{
   261    262       pNew->zFilename = 0;
   262    263     }
   263    264     pNew->nRef = 0;
   264    265     pNew->sz = sz;
   265    266     pNew->a = safe_realloc(0, sz);
   266    267     if( sz>0 ) memcpy(pNew->a, pData, sz);
................................................................................
  1051   1052         g.nDb = 1;
  1052   1053         sqlFuzz = 1;
  1053   1054       }
  1054   1055     
  1055   1056       /* Print the description, if there is one */
  1056   1057       if( !quietFlag ){
  1057   1058         zDbName = azSrcDb[iSrcDb];
  1058         -      i = strlen(zDbName) - 1;
         1059  +      i = (int)strlen(zDbName) - 1;
  1059   1060         while( i>0 && zDbName[i-1]!='/' && zDbName[i-1]!='\\' ){ i--; }
  1060   1061         zDbName += i;
  1061   1062         sqlite3_prepare_v2(db, "SELECT msg FROM readme", -1, &pStmt, 0);
  1062   1063         if( pStmt && sqlite3_step(pStmt)==SQLITE_ROW ){
  1063   1064           printf("%s: %s\n", zDbName, sqlite3_column_text(pStmt,0));
  1064   1065         }
  1065   1066         sqlite3_finalize(pStmt);