directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r450665 - /directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java
Date Thu, 28 Sep 2006 02:18:08 GMT
Author: trustin
Date: Wed Sep 27 19:18:07 2006
New Revision: 450665

URL: http://svn.apache.org/viewvc?view=rev&rev=450665
Log:
Found that CompressionFilter doesn't release the input buffers.

Modified:
    directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java

Modified: directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java
URL: http://svn.apache.org/viewvc/directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java?view=diff&rev=450665&r1=450664&r2=450665
==============================================================================
--- directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java
(original)
+++ directory/trunks/mina/filter-compression/src/main/java/org/apache/mina/filter/CompressionFilter.java
Wed Sep 27 19:18:07 2006
@@ -164,7 +164,7 @@
 
         ByteBuffer inBuffer = ( ByteBuffer ) message;
         ByteBuffer outBuffer = inflater.inflate( inBuffer );
-
+        inBuffer.release();
         nextFilter.messageReceived( session, outBuffer );
     }
 
@@ -195,9 +195,8 @@
         }
 
         ByteBuffer inBuffer = ( ByteBuffer ) writeRequest.getMessage();
-
         ByteBuffer outBuf = deflater.deflate( inBuffer );
-
+        inBuffer.release();
         nextFilter.filterWrite( session, new WriteRequest( outBuf, writeRequest
                 .getFuture() ) );
     }



Mime
View raw message