elharo opened a new issue, #381: URL: https://github.com/apache/maven-shared-utils/issues/381
Constructors accepting a `String lineIndent` parameter document that it "can be null" (e.g. `PrettyPrintXMLWriter(Writer, String)`), but then call `lineIndent.toCharArray()` without a null check, throwing `NullPointerException`. Impacted constructors: - `PrettyPrintXMLWriter(PrintWriter, String)` (line 65) → `PrettyPrintXMLWriter(PrintWriter, String, String, String)` (line 98) - `PrettyPrintXMLWriter(Writer, String)` (line 73) - `PrettyPrintXMLWriter(Writer, String, String, String)` (line 107) - `PrettyPrintXMLWriter(PrintWriter, String, String, String, String)` (line 138) Also `setLineSeparator(String)` and `setLineIndenter(String)` have the same pattern, though their Javadocs don't say null is allowed. When null is passed, the expected behavior should be to fall back to the default: two spaces for line indent, newline for line separator. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
