rgoers commented on a change in pull request #332: LOG4J2-2760: Fixes 
RollingFileAppender with DirectWriteRolloverStrategy and HtmlLayout
URL: https://github.com/apache/logging-log4j2/pull/332#discussion_r376753729
 
 

 ##########
 File path: 
log4j-core/src/main/java/org/apache/logging/log4j/core/appender/OutputStreamManager.java
 ##########
 @@ -164,6 +164,7 @@ public boolean hasOutputStream() {
     protected OutputStream getOutputStream() throws IOException {
         if (outputStream == null) {
             outputStream = createOutputStream();
+            setOutputStream(outputStream); // Needed so the header will be 
written
 
 Review comment:
   It seems like this should be
   ```
       if (outputSteam == null) {
           setOutputStream(createOutputStream);
   ```
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to