summaryrefslogtreecommitdiff
path: root/extra/sqlite/xbmc.patch
diff options
context:
space:
mode:
Diffstat (limited to 'extra/sqlite/xbmc.patch')
-rw-r--r--extra/sqlite/xbmc.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/extra/sqlite/xbmc.patch b/extra/sqlite/xbmc.patch
new file mode 100644
index 000000000..3a58dd242
--- /dev/null
+++ b/extra/sqlite/xbmc.patch
@@ -0,0 +1,22 @@
+Index: src/where.c
+==================================================================
+--- src/sqlite3.c
++++ src/sqlite3.c
+@@ -876,11 +876,14 @@
+ while( pScan->iEquiv<=pScan->nEquiv ){
+ iCur = pScan->aEquiv[pScan->iEquiv-2];
+ iColumn = pScan->aEquiv[pScan->iEquiv-1];
+ while( (pWC = pScan->pWC)!=0 ){
+ for(pTerm=pWC->a+k; k<pWC->nTerm; k++, pTerm++){
+- if( pTerm->leftCursor==iCur && pTerm->u.leftColumn==iColumn ){
++ if( pTerm->leftCursor==iCur
++ && pTerm->u.leftColumn==iColumn
++ && (pScan->iEquiv<=2 || !ExprHasProperty(pTerm->pExpr, EP_FromJoin))
++ ){
+ if( (pTerm->eOperator & WO_EQUIV)!=0
+ && pScan->nEquiv<ArraySize(pScan->aEquiv)
+ ){
+ int j;
+ pX = sqlite3ExprSkipCollate(pTerm->pExpr->pRight);
+
+