mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 16:48:19 +00:00
bug fix (and typo fix) for vector+scalar boolean operations
This commit is contained in:
parent
cff68b4371
commit
b811a8e7a6
2 changed files with 2 additions and 2 deletions
|
@ -1798,7 +1798,7 @@ Val* BoolExpr::Eval(Frame* f) const
|
||||||
|
|
||||||
VectorVal* result = 0;
|
VectorVal* result = 0;
|
||||||
|
|
||||||
// It's either and EXPR_AND_AND or an EXPR_OR_OR.
|
// It's either an EXPR_AND_AND or an EXPR_OR_OR.
|
||||||
bool is_and = (tag == EXPR_AND_AND);
|
bool is_and = (tag == EXPR_AND_AND);
|
||||||
|
|
||||||
if ( scalar_v->IsZero() == is_and )
|
if ( scalar_v->IsZero() == is_and )
|
||||||
|
|
|
@ -3226,7 +3226,7 @@ bool VectorVal::AssignRepeat(unsigned int index, unsigned int how_many,
|
||||||
ResizeAtLeast(index + how_many);
|
ResizeAtLeast(index + how_many);
|
||||||
|
|
||||||
for ( unsigned int i = index; i < index + how_many; ++i )
|
for ( unsigned int i = index; i < index + how_many; ++i )
|
||||||
if ( ! Assign(i, element ) )
|
if ( ! Assign(i, element->Ref() ) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue