/ Check-in [8123283e]
Login

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

Overview
Comment:Add an ALWAYS() around a always-true test in where.c.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 8123283ee1a360586a1721a56b4db15718c25ee0
User & Date: drh 2011-02-17 13:33:15
Context
2011-02-17
13:52
Remove an assert() that was made redundant by the previous checkin. check-in: 21db7191 user: drh tags: trunk
13:33
Add an ALWAYS() around a always-true test in where.c. check-in: 8123283e user: drh tags: trunk
2011-02-16
23:32
Fix harmless compiler warnings in the query planner. check-in: 31fc4ba6 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/where.c.

  1889   1889         Bitmask cMask = iCol>=BMS ? ((Bitmask)1)<<(BMS-1) : ((Bitmask)1)<<iCol;
  1890   1890         if( (idxCols & cMask)==0 ){
  1891   1891           Expr *pX = pTerm->pExpr;
  1892   1892           idxCols |= cMask;
  1893   1893           pIdx->aiColumn[n] = pTerm->u.leftColumn;
  1894   1894           pColl = sqlite3BinaryCompareCollSeq(pParse, pX->pLeft, pX->pRight);
  1895   1895           assert( pColl!=0 || pParse->nErr>0 );
  1896         -        pIdx->azColl[n] = pColl ? pColl->zName : "BINARY";
         1896  +        pIdx->azColl[n] = ALWAYS(pColl) ? pColl->zName : "BINARY";
  1897   1897           n++;
  1898   1898         }
  1899   1899       }
  1900   1900     }
  1901   1901     assert( (u32)n==pLevel->plan.nEq );
  1902   1902   
  1903   1903     /* Add additional columns needed to make the automatic index into