You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by re...@apache.org on 2021/04/09 01:12:31 UTC

[cxf] branch 3.4.x-fixes updated: CXF-8442: remove close() and doClose(), the complex relationships between these methods led to the issues that isClosed flag being set before closing the streams (as the result, streams stayed open)

This is an automated email from the ASF dual-hosted git repository.

reta pushed a commit to branch 3.4.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git


The following commit(s) were added to refs/heads/3.4.x-fixes by this push:
     new b15ce32  CXF-8442: remove close() and doClose(), the complex relationships between these methods led to the issues that isClosed flag being set before closing the streams (as the result, streams stayed open)
b15ce32 is described below

commit b15ce32e79cd7d3aca3fcc652686690c9745b8d8
Author: reta <dr...@gmail.com>
AuthorDate: Thu Apr 8 21:11:48 2021 -0400

    CXF-8442: remove close() and doClose(), the complex relationships between these methods led to the issues that isClosed flag being set before closing the streams (as the result, streams stayed open)
    
    (cherry picked from commit 7d2928fc88add3b7fae27144d89c07b2801c8aee)
---
 .../java/org/apache/cxf/io/CacheAndWriteOutputStream.java  | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/core/src/main/java/org/apache/cxf/io/CacheAndWriteOutputStream.java b/core/src/main/java/org/apache/cxf/io/CacheAndWriteOutputStream.java
index 482e68c..d89edb9 100644
--- a/core/src/main/java/org/apache/cxf/io/CacheAndWriteOutputStream.java
+++ b/core/src/main/java/org/apache/cxf/io/CacheAndWriteOutputStream.java
@@ -61,19 +61,7 @@ public class CacheAndWriteOutputStream extends CachedOutputStream {
     public OutputStream getFlowThroughStream() {
         return flowThroughStream;
     }
-
-    @Override
-    protected void doClose() throws IOException {
-        super.doClose();
-        isClosed = true;
-    }
-
-    @Override
-    public void close() throws IOException {
-        super.close();
-        isClosed = true;
-    }
-
+    
     @Override
     protected void onWrite() throws IOException {
         // does nothing