Actions
Bug #2177
closedNullPointerException with literal FilterExpression
Start date:
2014-10-13
Due date:
% Done:
100%
Estimated time:
Legacy ID:
Applies to branch:
9.6
Fix Committed on Branch:
9.6
Fixed in Maintenance Release:
Platforms:
Description
If a filter expression after optimization reduces to something like (1 to 20)[89], where both operands are literals and the index is out of range for the length of the sequence, a NullPointerException occurs rather than returning the empty sequence.
Problem code is at line 1121 in FilterExpression.iterate()
return ((Literal)base).getValue().itemAt(pos - 1).iterate();
where itemAt() can return null.
There is also another instance a few lines earlier where the base expression is a variable reference.
Please register to edit this issue
Actions