On Wed, 27 Jan 2021 06:33:01 GMT, Joe Wang <jo...@openjdk.org> wrote:

>> Please review a patch to add an explicit control over whether a newline 
>> should be added after the XML header. This is done by adding a DOM 
>> LSSerializer property "jdk-is-standalone" and System property 
>> "jdk.xml.isStandalone". 
>> 
>> This change addresses an incompatibility introduced during 7u4 as an update 
>> to Xalan 2.7.1.
>
> Joe Wang has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Update: add javadoc for impl specific features and properties in 
> module-info; update the patch accordingly.

src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/LSSerializerImpl.java
 line 362:

> 360:         // JDK specific property jdk-is-standalone
> 361:         String p = 
> SecuritySupport.getSystemProperty(DOMConstants.SP_IS_STANDALONE);
> 362:         if (p == null || p.equals("")) {

Although I see it aligns with other locations, `p.isEmpty()` is better?

-------------

PR: https://git.openjdk.java.net/jdk/pull/2041

Reply via email to