Fix compiler warnings.
FossilOrigin-Name: 364ac333b030f0e3372937df723f1098183da87913ba0e8ae162864ee24a50d3
This commit is contained in:
parent
47be3b23e9
commit
af2770f842
@ -176,12 +176,11 @@ static int makeDirectory(
|
||||
if( zCopy==0 ){
|
||||
rc = SQLITE_NOMEM;
|
||||
}else{
|
||||
int nCopy = strlen(zCopy);
|
||||
int nCopy = (int)strlen(zCopy);
|
||||
int i = 1;
|
||||
|
||||
while( rc==SQLITE_OK ){
|
||||
struct stat sStat;
|
||||
int rc;
|
||||
|
||||
for(; zCopy[i]!='/' && i<nCopy; i++);
|
||||
if( i==nCopy ) break;
|
||||
@ -634,7 +633,7 @@ static int fsdirFilter(
|
||||
pCur->zBase = (const char*)sqlite3_value_text(argv[1]);
|
||||
}
|
||||
if( pCur->zBase ){
|
||||
pCur->nBase = strlen(pCur->zBase)+1;
|
||||
pCur->nBase = (int)strlen(pCur->zBase)+1;
|
||||
pCur->zPath = sqlite3_mprintf("%s/%s", pCur->zBase, zDir);
|
||||
}else{
|
||||
pCur->zPath = sqlite3_mprintf("%s", zDir);
|
||||
|
16
manifest
16
manifest
@ -1,5 +1,5 @@
|
||||
C Revise\sdetection\sof\s'tclsh.exe'\sin\sthe\sMakefile\sfor\sMSVC.
|
||||
D 2018-01-05T01:22:37.774
|
||||
C Fix\scompiler\swarnings.
|
||||
D 2018-01-05T14:55:43.233
|
||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||
F Makefile.in 1b11037c5ed3399a79433cc82c59b5e36a7b3a3e4e195bb27640d0d2145e03e1
|
||||
@ -276,7 +276,7 @@ F ext/misc/compress.c 122faa92d25033d6c3f07c39231de074ab3d2e83
|
||||
F ext/misc/csv.c 1a009b93650732e22334edc92459c4630b9fa703397cbb3c8ca279921a36ca11
|
||||
F ext/misc/dbdump.c 3509fa6b8932d04e932d6b6b827b6a82ca362781b8e8f3c77336f416793e215e
|
||||
F ext/misc/eval.c f971962e92ebb8b0a4e6b62949463ee454d88fa2
|
||||
F ext/misc/fileio.c 868aa0572b08484323b172918882d5f8444e287b1e29e1d1b161633cf03aed10
|
||||
F ext/misc/fileio.c 864984342ede6775976322a3a2731be5e3a70a2c71557e489e1730bd8ca57dd2
|
||||
F ext/misc/fuzzer.c 7c64b8197bb77b7d64eff7cac7848870235d4c25
|
||||
F ext/misc/ieee754.c f190d0cc5182529acb15babd177781be1ac1718c
|
||||
F ext/misc/json1.c dbe086615b9546c156bf32b9378fc09383b58bd17513b866cfd24c1e15281984
|
||||
@ -483,7 +483,7 @@ F src/random.c 80f5d666f23feb3e6665a6ce04c7197212a88384
|
||||
F src/resolve.c bbee7e31d369a18a2f4836644769882e9c5d40ef4a3af911db06410b65cb3730
|
||||
F src/rowset.c 7b7e7e479212e65b723bf40128c7b36dc5afdfac
|
||||
F src/select.c 8b22abe193e4d8243befa2038e4ae2405802fed1c446e5e502d11f652e09ba74
|
||||
F src/shell.c.in f57fa72ec6aa5e330966adaa51a476f08a877a82e482cd26a06a7d7c1ecb666b
|
||||
F src/shell.c.in 17fc28661aae277767db63fa90e644b8c9bf1242fbd167dcc2e7af0f0e620bb7
|
||||
F src/sqlite.h.in 1f1a2da222ec57465794e8984d77f32d0bd0da80cdc136beadda461a0be9d80c
|
||||
F src/sqlite3.rc 5121c9e10c3964d5755191c80dd1180c122fc3a8
|
||||
F src/sqlite3ext.h c02d628cca67f3889c689d82d25c3eb45e2c155db08e4c6089b5840d64687d34
|
||||
@ -1694,7 +1694,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 0bc3b76ec9b83f3034e282ea0369a53673e2cb64dde42e8cf5e800f6d642d527
|
||||
R ea85632748cb8c061fa075c4e05b7d5d
|
||||
U mistachkin
|
||||
Z a7a75d6fbb0bbc541be826de9dbf52e8
|
||||
P 45fabd868dc690894f5a911d373a3d6410ba2d95d177307a42009afc8ae296cc
|
||||
R 67924405c342403978f2d6d8e94eaa8e
|
||||
U drh
|
||||
Z e8ddc1cfcd8bdce50b891a625082402b
|
||||
|
@ -1 +1 @@
|
||||
45fabd868dc690894f5a911d373a3d6410ba2d95d177307a42009afc8ae296cc
|
||||
364ac333b030f0e3372937df723f1098183da87913ba0e8ae162864ee24a50d3
|
@ -1955,7 +1955,7 @@ static void displayLinuxIoStats(FILE *out){
|
||||
};
|
||||
int i;
|
||||
for(i=0; i<ArraySize(aTrans); i++){
|
||||
int n = (int)strlen(aTrans[i].zPattern);
|
||||
int n = strlen30(aTrans[i].zPattern);
|
||||
if( strncmp(aTrans[i].zPattern, z, n)==0 ){
|
||||
utf8_printf(out, "%-36s %s", aTrans[i].zDesc, &z[n]);
|
||||
break;
|
||||
@ -3134,7 +3134,7 @@ static char **readline_completion(const char *zText, int iStart, int iEnd){
|
||||
** Linenoise completion callback
|
||||
*/
|
||||
static void linenoise_completion(const char *zLine, linenoiseCompletions *lc){
|
||||
int nLine = (int)strlen(zLine);
|
||||
int nLine = strlen30(zLine);
|
||||
int i, iStart;
|
||||
sqlite3_stmt *pStmt = 0;
|
||||
char *zSql;
|
||||
@ -3360,7 +3360,7 @@ static int sql_trace_callback(
|
||||
UNUSED_PARAMETER(pP);
|
||||
if( f ){
|
||||
const char *z = (const char*)pX;
|
||||
int i = (int)strlen(z);
|
||||
int i = strlen30(z);
|
||||
while( i>0 && z[i-1]==';' ){ i--; }
|
||||
utf8_printf(f, "%.*s;\n", i, z);
|
||||
}
|
||||
@ -3549,7 +3549,7 @@ static void tryToCloneData(
|
||||
char *zInsert = 0;
|
||||
int rc;
|
||||
int i, j, n;
|
||||
int nTable = (int)strlen(zTable);
|
||||
int nTable = strlen30(zTable);
|
||||
int k = 0;
|
||||
int cnt = 0;
|
||||
const int spinRate = 10000;
|
||||
@ -3570,7 +3570,7 @@ static void tryToCloneData(
|
||||
}
|
||||
sqlite3_snprintf(200+nTable,zInsert,
|
||||
"INSERT OR IGNORE INTO \"%s\" VALUES(?", zTable);
|
||||
i = (int)strlen(zInsert);
|
||||
i = strlen30(zInsert);
|
||||
for(j=1; j<n; j++){
|
||||
memcpy(zInsert+i, ",?", 2);
|
||||
i += 2;
|
||||
@ -4152,7 +4152,7 @@ static int lintFkeyIndexes(
|
||||
const char *zGlobIPK = "SEARCH TABLE * USING INTEGER PRIMARY KEY (rowid=?)";
|
||||
|
||||
for(i=2; i<nArg; i++){
|
||||
int n = (int)strlen(azArg[i]);
|
||||
int n = strlen30(azArg[i]);
|
||||
if( n>1 && sqlite3_strnicmp("-verbose", azArg[i], n)==0 ){
|
||||
bVerbose = 1;
|
||||
}
|
||||
@ -4255,7 +4255,7 @@ static int lintDotCommand(
|
||||
int nArg /* Number of entries in azArg[] */
|
||||
){
|
||||
int n;
|
||||
n = (nArg>=2 ? (int)strlen(azArg[1]) : 0);
|
||||
n = (nArg>=2 ? strlen30(azArg[1]) : 0);
|
||||
if( n<1 || sqlite3_strnicmp(azArg[1], "fkey-indexes", n) ) goto usage;
|
||||
return lintFkeyIndexes(pState, azArg, nArg);
|
||||
|
||||
@ -4517,7 +4517,7 @@ static int arParseCommand(
|
||||
pAr->nArg = nArg-iArg;
|
||||
break;
|
||||
}
|
||||
n = strlen(z);
|
||||
n = strlen30(z);
|
||||
|
||||
if( z[1]!='-' ){
|
||||
int i;
|
||||
@ -4557,7 +4557,7 @@ static int arParseCommand(
|
||||
struct ArSwitch *pOpt; /* Iterator */
|
||||
for(pOpt=&aSwitch[0]; pOpt<pEnd; pOpt++){
|
||||
const char *zLong = pOpt->zLong;
|
||||
if( (n-2)<=(int)strlen(zLong) && 0==memcmp(&z[2], zLong, n-2) ){
|
||||
if( (n-2)<=strlen30(zLong) && 0==memcmp(&z[2], zLong, n-2) ){
|
||||
if( pMatch ){
|
||||
return arErrorMsg("ambiguous option: %s",z);
|
||||
}else{
|
||||
@ -4610,7 +4610,7 @@ static int arCheckEntries(sqlite3 *db, ArCommand *pAr){
|
||||
}
|
||||
for(i=0; i<pAr->nArg && rc==SQLITE_OK; i++){
|
||||
char *z = pAr->azArg[i];
|
||||
int n = strlen(z);
|
||||
int n = strlen30(z);
|
||||
int bOk = 0;
|
||||
while( n>0 && z[n-1]=='/' ) n--;
|
||||
z[n] = '\0';
|
||||
@ -5025,7 +5025,7 @@ static int expertDotCommand(
|
||||
char *z = azArg[i];
|
||||
int n;
|
||||
if( z[0]=='-' && z[1]=='-' ) z++;
|
||||
n = strlen(z);
|
||||
n = strlen30(z);
|
||||
if( n>=2 && 0==strncmp(z, "-verbose", n) ){
|
||||
pState->expert.bVerbose = 1;
|
||||
}
|
||||
@ -5908,7 +5908,7 @@ static int do_meta_command(char *zLine, ShellState *p){
|
||||
|
||||
if( c=='m' && strncmp(azArg[0], "mode", n)==0 ){
|
||||
const char *zMode = nArg>=2 ? azArg[1] : "";
|
||||
int n2 = (int)strlen(zMode);
|
||||
int n2 = strlen30(zMode);
|
||||
int c2 = zMode[0];
|
||||
if( c2=='l' && n2>2 && strncmp(azArg[1],"lines",n2)==0 ){
|
||||
p->mode = MODE_Line;
|
||||
@ -7147,8 +7147,7 @@ static int do_meta_command(char *zLine, ShellState *p){
|
||||
rc = 1;
|
||||
goto meta_command_exit;
|
||||
}
|
||||
rc = sqlite3_user_authenticate(p->db, azArg[2], azArg[3],
|
||||
(int)strlen(azArg[3]));
|
||||
rc = sqlite3_user_authenticate(p->db, azArg[2], azArg[3], strlen30(azArg[3]));
|
||||
if( rc ){
|
||||
utf8_printf(stderr, "Authentication failed for user %s\n", azArg[2]);
|
||||
rc = 1;
|
||||
@ -7159,8 +7158,7 @@ static int do_meta_command(char *zLine, ShellState *p){
|
||||
rc = 1;
|
||||
goto meta_command_exit;
|
||||
}
|
||||
rc = sqlite3_user_add(p->db, azArg[2],
|
||||
azArg[3], (int)strlen(azArg[3]),
|
||||
rc = sqlite3_user_add(p->db, azArg[2], azArg[3], strlen30(azArg[3]),
|
||||
booleanValue(azArg[4]));
|
||||
if( rc ){
|
||||
raw_printf(stderr, "User-Add failed: %d\n", rc);
|
||||
@ -7172,8 +7170,7 @@ static int do_meta_command(char *zLine, ShellState *p){
|
||||
rc = 1;
|
||||
goto meta_command_exit;
|
||||
}
|
||||
rc = sqlite3_user_change(p->db, azArg[2],
|
||||
azArg[3], (int)strlen(azArg[3]),
|
||||
rc = sqlite3_user_change(p->db, azArg[2], azArg[3], strlen30(azArg[3]),
|
||||
booleanValue(azArg[4]));
|
||||
if( rc ){
|
||||
raw_printf(stderr, "User-Edit failed: %d\n", rc);
|
||||
|
Loading…
Reference in New Issue
Block a user