Task #119476 - sqlite-3.53.1-1.fc45/scan-results.err
back to task #119476download
Error: COMPILER_WARNING (CWE-704):
sqlite-src-3530100/autosetup/jimsh0.c: scope_hint: In function ‘aio_cmd_gets’
sqlite-src-3530100/autosetup/jimsh0.c:2643:16: warning[-Wdiscarded-qualifiers]: assignment discards ‘const’ qualifier from pointer target type
# 2643 | nl = memchr(pt + offset, '\n', len - offset);
# | ^
# 2641| if (af->readbuf) {
# 2642| const char *pt = Jim_GetString(af->readbuf, &len);
# 2643|-> nl = memchr(pt + offset, '\n', len - offset);
# 2644| if (nl) {
# 2645|
Error: CPPCHECK_WARNING (CWE-457):
sqlite-src-3530100/autosetup/jimsh0.c:21487: warning[uninitvar]: Uninitialized variable: params
#21485| len += extra;
#21486| buf = Jim_Alloc(len + 1);
#21487|-> len = snprintf(buf, len + 1, format, params[0], params[1], params[2], params[3], params[4]);
#21488|
#21489| va_end(args);
Error: COMPILER_WARNING (CWE-686):
sqlite-src-3530100/conftest__.c:1:13: warning[-Wbuiltin-declaration-mismatch]: conflicting types for built-in function ‘ceil’; expected ‘double(double)’
# 1 | extern void ceil(void);
# | ^~~~
sqlite-src-3530100/conftest__.c:1:1: note: ‘ceil’ is declared in header ‘<math.h>’
# +++ |+#include <math.h>
# 1 | extern void ceil(void);
Error: COMPILER_WARNING (CWE-686):
sqlite-src-3530100/conftest__.c:1:13: warning[-Wbuiltin-declaration-mismatch]: conflicting types for built-in function ‘ceil’; expected ‘double(double)’
Error: COMPILER_WARNING (CWE-686):
sqlite-src-3530100/conftest__.c:1:13: warning[-Wbuiltin-declaration-mismatch]: conflicting types for built-in function ‘isnan’; expected ‘int()’
# 1 | extern void isnan(void);
# | ^~~~~
sqlite-src-3530100/conftest__.c:1:1: note: ‘isnan’ is declared in header ‘<math.h>’
# +++ |+#include <math.h>
# 1 | extern void isnan(void);
Error: COMPILER_WARNING (CWE-686):
sqlite-src-3530100/conftest__.c:1:13: warning[-Wbuiltin-declaration-mismatch]: conflicting types for built-in function ‘isnan’; expected ‘int()’
Error: COMPILER_WARNING (CWE-563):
sqlite-src-3530100/conftest__.c: scope_hint: In function ‘main’
sqlite-src-3530100/conftest__.c:3:8: warning[-Wunused-variable]: unused variable ‘_x’
# 3 | int8_t _x;
# | ^~
Error: COMPILER_WARNING (CWE-563):
sqlite-src-3530100/conftest__.c: scope_hint: In function ‘main’
sqlite-src-3530100/conftest__.c:3:9: warning[-Wunused-variable]: unused variable ‘_x’
# 3 | int16_t _x;
# | ^~
Error: COMPILER_WARNING (CWE-563):
sqlite-src-3530100/conftest__.c: scope_hint: In function ‘main’
sqlite-src-3530100/conftest__.c:3:10: warning[-Wunused-variable]: unused variable ‘_x’
# 3 | intptr_t _x;
# | ^~
Error: COMPILER_WARNING (CWE-563):
sqlite-src-3530100/conftest__.c: scope_hint: In function ‘main’
sqlite-src-3530100/conftest__.c:3:11: warning[-Wunused-variable]: unused variable ‘_x’
# 3 | uintptr_t _x;
# | ^~
Error: COMPILER_WARNING (CWE-563):
sqlite-src-3530100/conftest__.c:3:12: warning[-Wunused-variable]: unused variable ‘_x’
Error: COMPILER_WARNING:
sqlite-src-3530100/sqlite3.c: scope_hint: In function ‘sqlite3Pragma’
sqlite-src-3530100/sqlite3.c:146325:13: warning[-Wunused-but-set-variable=]: variable ‘nIdx’ set but not used
#146325 | int nIdx; /* Number of indexes on pTab */
# | ^~~~
#146323| Table *pTab = sqliteHashData(x); /* Current table */
#146324| Index *pIdx; /* An index on pTab */
#146325|-> int nIdx; /* Number of indexes on pTab */
#146326| if( tableSkipIntegrityCheck(pTab,pObjTab) ) continue;
#146327| if( HasRowid(pTab) ) cnt++;
Error: COMPILER_WARNING:
sqlite-src-3530100/sqlite3_analyzer.c: scope_hint: In function ‘sqlite3Pragma’
sqlite-src-3530100/sqlite3_analyzer.c:146349:13: warning[-Wunused-but-set-variable=]: variable ‘nIdx’ set but not used
#146349 | int nIdx; /* Number of indexes on pTab */
# | ^~~~
#146347| Table *pTab = sqliteHashData(x); /* Current table */
#146348| Index *pIdx; /* An index on pTab */
#146349|-> int nIdx; /* Number of indexes on pTab */
#146350| if( tableSkipIntegrityCheck(pTab,pObjTab) ) continue;
#146351| if( HasRowid(pTab) ) cnt++;
Error: COMPILER_WARNING (CWE-1164):
sqlite-src-3530100/sqlite3_analyzer.c: scope_hint: At top level
sqlite-src-3530100/sqlite3_analyzer.c:192538:21: warning[-Wunused-function]: ‘sqlite3ConnectionBlocked’ defined but not used
#192538 | SQLITE_PRIVATE void sqlite3ConnectionBlocked(sqlite3 *db, sqlite3 *pBlocker){
# | ^~~~~~~~~~~~~~~~~~~~~~~~
#192536| ** until connection pBlocker concludes its current transaction.
#192537| */
#192538|-> SQLITE_PRIVATE void sqlite3ConnectionBlocked(sqlite3 *db, sqlite3 *pBlocker){
#192539| enterMutex();
#192540| if( db->pBlockingConnection==0 && db->pUnlockConnection==0 ){
Error: GCC_ANALYZER_WARNING (CWE-686):
sqlite-src-3530100/tool/lemon.c:188:13: warning[-Wanalyzer-va-arg-type-mismatch]: ‘va_arg’ expected ‘int’ but received ‘char *’ for variadic argument 1 of ‘ap’
sqlite-src-3530100/tool/lemon.c:4425:6: enter_function: entry to ‘ReportTable’
sqlite-src-3530100/tool/lemon.c:4453:8: call_function: calling ‘tplt_open’ from ‘ReportTable’
# 186| }
# 187| if( c=='d' ){
# 188|-> int v = va_arg(ap, int);
# 189| if( v<0 ){
# 190| lemon_addtext(str, &nUsed, "-", 1, iWidth);
Error: GCC_ANALYZER_WARNING (CWE-686):
sqlite-src-3530100/tool/lemon.c:203:9: warning[-Wanalyzer-va-arg-type-mismatch]: ‘va_arg’ expected ‘const char *’ but received ‘int’ for variadic argument 1 of ‘ap’
sqlite-src-3530100/tool/lemon.c:4425:6: enter_function: entry to ‘ReportTable’
sqlite-src-3530100/tool/lemon.c:4453:8: call_function: calling ‘tplt_open’ from ‘ReportTable’
# 201| lemon_addtext(str, &nUsed, &zTemp[sizeof(zTemp)-k], k, iWidth);
# 202| }else if( c=='s' ){
# 203|-> z = va_arg(ap, const char*);
# 204| lemon_addtext(str, &nUsed, z, -1, iWidth);
# 205| }else if( c=='.' && memcmp(&zFormat[i], ".*s", 3)==0 ){
Error: GCC_ANALYZER_WARNING (CWE-686):
sqlite-src-3530100/tool/lemon.c:207:9: warning[-Wanalyzer-va-arg-type-mismatch]: ‘va_arg’ expected ‘int’ but received ‘char *’ for variadic argument 1 of ‘ap’
sqlite-src-3530100/tool/lemon.c:4425:6: enter_function: entry to ‘ReportTable’
sqlite-src-3530100/tool/lemon.c:4453:8: call_function: calling ‘tplt_open’ from ‘ReportTable’
# 205| }else if( c=='.' && memcmp(&zFormat[i], ".*s", 3)==0 ){
# 206| i += 2;
# 207|-> k = va_arg(ap, int);
# 208| z = va_arg(ap, const char*);
# 209| lemon_addtext(str, &nUsed, z, k, iWidth);
Error: GCC_ANALYZER_WARNING (CWE-476):
sqlite-src-3530100/tool/lemon.c:2140:3: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘cp’
sqlite-src-3530100/tool/lemon.c:2217:5: enter_function: entry to ‘OptInit’
sqlite-src-3530100/tool/lemon.c:2225:14: branch_true: following ‘true’ branch...
sqlite-src-3530100/tool/lemon.c:2226:11: branch_true: ...to here
sqlite-src-3530100/tool/lemon.c:2229:19: call_function: calling ‘handleswitch’ from ‘OptInit’
# 2138| cp = strchr(g_argv[i],'=');
# 2139| assert( cp!=0 );
# 2140|-> *cp = 0;
# 2141| for(j=0; op[j].label; j++){
# 2142| if( strcmp(g_argv[i],op[j].label)==0 ) break;
Error: GCC_ANALYZER_WARNING (CWE-476):
sqlite-src-3530100/tool/lemon.c:5573:16: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘x’
sqlite-src-3530100/tool/lemon.c:5564:16: enter_function: entry to ‘Symbol_new’
sqlite-src-3530100/tool/lemon.c:5569:5: branch_true: following ‘true’ branch...
sqlite-src-3530100/tool/lemon.c:5570:27: branch_true: ...to here
sqlite-src-3530100/tool/lemon.c:5570:27: call_function: calling ‘lemon_calloc’ from ‘Symbol_new’
sqlite-src-3530100/tool/lemon.c:5570:27: return_function: returning to ‘Symbol_new’ from ‘lemon_calloc’
sqlite-src-3530100/tool/lemon.c:5572:16: call_function: calling ‘Strsafe’ from ‘Symbol_new’
sqlite-src-3530100/tool/lemon.c:5572:16: return_function: returning to ‘Symbol_new’ from ‘Strsafe’
sqlite-src-3530100/tool/lemon.c:5572:5: release_memory: ‘x’ is NULL
sqlite-src-3530100/tool/lemon.c:5573:16: danger: dereference of NULL ‘x’
# 5571| MemoryCheck(sp);
# 5572| sp->name = Strsafe(x);
# 5573|-> sp->type = ISUPPER(*x) ? TERMINAL : NONTERMINAL;
# 5574| sp->rule = 0;
# 5575| sp->fallback = 0;
Error: GCC_ANALYZER_WARNING (CWE-401):
sqlite-src-3530100/tool/lemon.c:6031:25: warning[-Wanalyzer-malloc-leak]: leak of ‘<unknown>’
sqlite-src-3530100/tool/lemon.c:1425:16: enter_function: entry to ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: call_function: calling ‘newconfig’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: return_function: returning to ‘Configlist_add’ from ‘newconfig’
sqlite-src-3530100/tool/lemon.c:1439:16: call_function: calling ‘SetNew’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1439:16: return_function: returning to ‘Configlist_add’ from ‘SetNew’
sqlite-src-3530100/tool/lemon.c:1446:5: call_function: calling ‘Configtable_insert’ from ‘Configlist_add’
# 6029| h = confighash(oldnp->data) & (arrSize-1);
# 6030| newnp = &(array.tbl[i]);
# 6031|-> if( array.ht[h] ) array.ht[h]->from = &(newnp->next);
# 6032| newnp->next = array.ht[h];
# 6033| newnp->data = oldnp->data;
Error: GCC_ANALYZER_WARNING (CWE-401):
sqlite-src-3530100/tool/lemon.c:6035:7: warning[-Wanalyzer-malloc-leak]: leak of ‘<unknown>’
sqlite-src-3530100/tool/lemon.c:1425:16: enter_function: entry to ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: call_function: calling ‘newconfig’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: return_function: returning to ‘Configlist_add’ from ‘newconfig’
sqlite-src-3530100/tool/lemon.c:1439:16: call_function: calling ‘SetNew’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1439:16: return_function: returning to ‘Configlist_add’ from ‘SetNew’
sqlite-src-3530100/tool/lemon.c:1446:5: call_function: calling ‘Configtable_insert’ from ‘Configlist_add’
# 6033| newnp->data = oldnp->data;
# 6034| newnp->from = &(array.ht[h]);
# 6035|-> array.ht[h] = newnp;
# 6036| }
# 6037| *x4a = array;
Error: GCC_ANALYZER_WARNING (CWE-401):
sqlite-src-3530100/tool/lemon.c:6043:20: warning[-Wanalyzer-malloc-leak]: leak of ‘<unknown>’
sqlite-src-3530100/tool/lemon.c:1425:16: enter_function: entry to ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: call_function: calling ‘newconfig’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: return_function: returning to ‘Configlist_add’ from ‘newconfig’
sqlite-src-3530100/tool/lemon.c:1439:16: call_function: calling ‘SetNew’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1439:16: return_function: returning to ‘Configlist_add’ from ‘SetNew’
sqlite-src-3530100/tool/lemon.c:1446:5: call_function: calling ‘Configtable_insert’ from ‘Configlist_add’
# 6041| np = &(x4a->tbl[x4a->count++]);
# 6042| np->data = data;
# 6043|-> if( x4a->ht[h] ) x4a->ht[h]->from = &(np->next);
# 6044| np->next = x4a->ht[h];
# 6045| x4a->ht[h] = np;
Error: GCC_ANALYZER_WARNING (CWE-401):
sqlite-src-3530100/tool/lemon.c:6045:3: warning[-Wanalyzer-malloc-leak]: leak of ‘<unknown>’
sqlite-src-3530100/tool/lemon.c:1425:16: enter_function: entry to ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: call_function: calling ‘newconfig’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1436:11: return_function: returning to ‘Configlist_add’ from ‘newconfig’
sqlite-src-3530100/tool/lemon.c:1439:16: call_function: calling ‘SetNew’ from ‘Configlist_add’
sqlite-src-3530100/tool/lemon.c:1439:16: return_function: returning to ‘Configlist_add’ from ‘SetNew’
sqlite-src-3530100/tool/lemon.c:1446:5: call_function: calling ‘Configtable_insert’ from ‘Configlist_add’
# 6043| if( x4a->ht[h] ) x4a->ht[h]->from = &(np->next);
# 6044| np->next = x4a->ht[h];
# 6045|-> x4a->ht[h] = np;
# 6046| np->from = &(x4a->ht[h]);
# 6047| return 1;
Error: COMPILER_WARNING:
sqlite-src-3530100/tool/sqldiff.c: scope_hint: In function ‘all_tables_sql’
sqlite-src-3530100/tool/sqldiff.c:1826:9: warning[-Wunused-but-set-variable=]: variable ‘rc’ set but not used
# 1826 | int rc;
# | ^~
# 1824| const char *all_tables_sql(){
# 1825| if( g.bHandleVtab ){
# 1826|-> int rc;
# 1827|
# 1828| rc = sqlite3_exec(g.db,
Error: COMPILER_WARNING (CWE-704):
sqlite-src-3530100/tool/sqlite3_rsync.c: scope_hint: In function ‘hostSeparator’
sqlite-src-3530100/tool/sqlite3_rsync.c:2020:17: warning[-Wdiscarded-qualifiers]: initialization discards ‘const’ qualifier from pointer target type
# 2020 | char *zPath = strchr(zIn, ':');
# | ^~~~~~
# 2018| */
# 2019| static char *hostSeparator(const char *zIn){
# 2020|-> char *zPath = strchr(zIn, ':');
# 2021| if( zPath==0 ) return 0;
# 2022| #ifdef _WIN32