Fix segv on filter '(NP)'

Fixes the crash but the eval code is a bit of a
fuck up. It was evaluating children instead of
using recursion, and now we have lots more types
and expressions its all a bit of a mess.

Will need to rewrite to use recursion and it will
be a lot simpler!
This commit is contained in:
Mark Liversedge
2013-08-04 11:40:44 +01:00
parent 77278b2ed1
commit 2546b38ec2
2 changed files with 6 additions and 3 deletions

View File

@@ -160,8 +160,11 @@ void Leaf::validateFilter(DataFilter *df, Leaf *leaf)
}
break;
case Leaf::Logical : validateFilter(df, leaf->lvalue.l);
validateFilter(df, leaf->rvalue.l);
case Leaf::Logical :
{
validateFilter(df, leaf->lvalue.l);
if (leaf->op) validateFilter(df, leaf->rvalue.l);
}
break;
default:
break;