Bug #2378
closedNullPointerException using saxon:next-in-chain via JAXP interfaces
100%
Description
When a stylesheet containing saxon:next-in-chain is executed using the JAXP TransformerFactory interface, a NullPointerException occurs in SerializerFactoryPE.prepareNextStylesheet), because the PipelineConfiguration that is passed has a null Controller.
Updated by Michael Kay over 9 years ago
- Status changed from New to Resolved
Solution (a bit of a hack...) is to create method Serializer.getReceiver(PipelineConfiguration) and call this instead of Serializer.getReceiver(Configuration) from XsltTransformer.getDestinationReceiver(), supplying a PipelineConfiguration that knows about the Controller for the first stylesheet.
Patch committed for 9.6 and 9.7. Only tested for this one case currently.
Updated by O'Neil Delpratt over 9 years ago
- Status changed from Resolved to Closed
- % Done changed from 0 to 100
- Fixed in version set to 9.6.0.6
Bug fix applied in the Saxon 9.6.0.6 maintenance release.
Updated by Michael Kay over 9 years ago
- Status changed from Closed to In Progress
Reopened. The patch solved the NullPointerException and allowed the test to run successfully, but the results are wrong.
Updated by Michael Kay over 9 years ago
What was happening was that the serialization properties for the first transformation, including the saxon:next-in-chain property, were being used for the second transformation as well. This was causing a pipeline of three transformations instead of two (A B B rather than A B), so the second stylesheet was applied twice. The solution is to adjust the way serialization properties are set on the second transformation.
Updated by Michael Kay over 9 years ago
- Status changed from In Progress to Resolved
Committed a new patch for 9.6 and 9.7 which ignores the saxon:next-in-chain option if set on a s9api Serializer.
Updated by O'Neil Delpratt over 9 years ago
- Status changed from Resolved to Closed
- Fixed in version changed from 9.6.0.6 to 9.6.0.7
Bug fix applied in the Saxon 9.6.0.7 maintenance release.
Updated by O'Neil Delpratt almost 9 years ago
- Applies to branch 9.6 added
- Fix Committed on Branch 9.6 added
- Fixed in Maintenance Release 9.6.0.7 added
Please register to edit this issue