This is the right way to report a bug, and as soon as you encounter a bug, you
should report it here.
As for the current query, this is not a bug, it's a VS13 compiler peculiarity which they feel pertinent to report on, but which does
not affect the ability of SQLite to produce the correct result or function perfectly in any way - i.e. NOT a bug.
Feel free to fix it in your source to just hush the compiler (which introduces the risk for real bugs), or just ignore it and SQLite
will work perfectly.
Have a great day,
Ryan
On 2014/09/07 14:26, Joe Mucchiello wrote:
So I'm posting it here. The 3.8.6 Amalgam file generates an error in VS13 on
Windows:
sqlite3.c(77874): error C4703: potentially uninitialized local pointer variable
'pReadr' used
This is from the source file src/vbesort.c in a function called
vdbeSorterSetupMerge:
PmaReader *pReadr;
SortSubtask *pLast = &pSorter->aTask[pSorter->nTask-1];
rc = vdbeSortAllocUnpacked(pLast);
if( rc==SQLITE_OK ){
pReadr = (PmaReader*)sqlite3DbMallocZero(db, sizeof(PmaReader));
pSorter->pReader = pReadr;
if (pReadr == 0) rc = SQLITE_NOMEM;
}
if (rc == SQLITE_OK){
rc = vdbeIncrMergerNew(pLast, pMain, &pReadr->pIncr); -- << Error line
Here is my fix:
PmaReader *pReadr = 0;
SortSubtask *pLast = &pSorter->aTask[pSorter->nTask-1];
rc = vdbeSortAllocUnpacked(pLast);
if( rc==SQLITE_OK ){
pReadr = (PmaReader*)sqlite3DbMallocZero(db, sizeof(PmaReader));
pSorter->pReader = pReadr;
}
if (pReadr == 0) rc = SQLITE_NOMEM;
if (rc == SQLITE_OK){
rc = vdbeIncrMergerNew(pLast, pMain, &pReadr->pIncr);
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users