Sophie

Sophie

distrib > Mandriva > 2008.1 > i586 > by-pkgid > 061632773846e95af7ca7e88d7afa7b2 > files > 11

dbxml-2.3.10-2mdv2008.1.src.rpm

--- dbxml-2.3.10-original/dbxml/src/dbxml/optimizer/QueryPlanGenerator.cpp	2007-04-18 10:05:24.000000000 +0100
+++ dbxml-2.3.10/dbxml/src/dbxml/optimizer/QueryPlanGenerator.cpp	2007-08-08 11:32:10.000000000 +0100
@@ -1566,11 +1572,12 @@
 
 	else if(name == Or::name) {
 		UnionQP *unionOp = new (&memMgr_) UnionQP(&memMgr_);
+		result.operation = unionOp;
 		for(VectorOfASTNodes::iterator i = args.begin(); i != args.end(); ++i) {
 			PathResult ret = generate(*i, ids);
 			unionOp->addArg(ret.operation);
+			if(ret.operation == 0) result.operation = 0;
 		}
-		result.operation = unionOp;
 	}
 
 	// These operators use the presence of the node arguments, not their value