Hi John,

Another small bug fix for today. In query::doEvaluate , failures in the right 
part of an OR are not cascaded properly (since the line ierr = 
ht.sloppyCount(); hides it).

The following patch should fix this (this one applies on top of my previous 
patches, but the change is similar on top of r501):

diff --git a/src/query.cpp b/src/query.cpp
index 07bd49f..ccaa6b3 100755
--- a/src/query.cpp
+++ b/src/query.cpp
@@ -3565,9 +3565,10 @@ int ibis::query::doEvaluate(const ibis::qExpr* term,
        if (ierr >= 0) {
            ibis::bitvector b1;
            ierr = doEvaluate(term->getRight(), b1);
-           if (ierr > 0)
-               ht |= b1;
-           ierr = ht.sloppyCount();
+           if (ierr >= 0) {
+               if (ierr > 0) ht |= b1;
+               ierr = ht.sloppyCount();
+           }
        }
        break;
     }
@@ -3793,9 +3794,10 @@ int ibis::query::doEvaluate(const ibis::qExpr* term,
        if (ierr >= 0) {
            ibis::bitvector b1;
            ierr = doEvaluate(term->getRight(), mask, b1);
-           if (ierr > 0)
-               ht |= b1;
-           ierr = ht.sloppyCount();
+           if (ierr >= 0) {
+               if (ierr > 0) ht |= b1;
+               ierr = ht.sloppyCount();
+           }
        }
        break;
     }

Thanks,

Dominique Prunier
 APG Lead Developper
[cid:[email protected]]
 4388, rue Saint-Denis
 Bureau 309
 Montreal (Quebec)  H2J 2L1
 Tel. +1 514-842-6767  x310
 Fax +1 514-842-3989
 [email protected]<mailto:[email protected]>
 www.watch4net.com<http://www.watch4net.com/>

This message is for the designated recipient only and may contain privileged, 
proprietary, or otherwise private information. If you have received it in 
error, please notify the sender immediately and delete the original. Any other 
use of this electronic mail by you is prohibited.

Ce message est pour le récipiendaire désigné seulement et peut contenir des 
informations privilégiées, propriétaires ou autrement privées. Si vous l'avez 
reçu par erreur, S.V.P. avisez l'expéditeur immédiatement et effacez 
l'original. Toute autre utilisation de ce courrier électronique par vous est 
prohibée.

<<inline: image001.gif>>

_______________________________________________
FastBit-users mailing list
[email protected]
https://hpcrdm.lbl.gov/cgi-bin/mailman/listinfo/fastbit-users

Reply via email to