https://bz.apache.org/bugzilla/show_bug.cgi?id=66509

--- Comment #5 from Henry Iguaro <[email protected]> ---
Thank you for your response. I would like to clarify that
`XSLFSimpleShape#getAnchor()` already returns `null` in a couple of cases. The
current implementation checks for the presence of the `xfrm` element and
whether the `off` attribute is set, and returns `null` if either of these
conditions is false.

However, in the specific case that triggered this issue, the `xfrm` element was
present, the `off` attribute was missing, and the method did not return `null`,
causing the NPE. The proposed change addresses this specific case and ensures
that the method returns `null`. I also extended the approach to
`XSLFGroupShape#getAnchor()` for consistency.

As a user of the library, I believe that changing the method signature to throw
an exception would be excessive, and I do think that returning `null` is a
simple enough and not a terrible solution.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to