#895 NPE in SingletonAtomizer.getItemType()

v9.1
closed
Michael Kay
5
2012-10-08
2008-11-19
Michael Kay
No

A NullPointerException can occur in the method SingletonAtomizer.getItemType(). The problem occurs after a variable has been inlined because there is only a single reference (and the reference is not in a loop), for example

let $t := ....some expression.... return f($t)

It occurs because an expression is constructed that has no link to its "container". Two patches are being placed in Subversion:

(a) a patch that ensures that this particular optimization rewrite sets the container of the new expression correctly

(b) a patch that makes the SingletonAtomizer class resilient to the situation where the container of an expression is not set.

Discussion

  • Michael Kay
    Michael Kay
    2008-12-17

    Fixed in 9.1.0.5