directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r440626 - in /directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec: ProtocolCodecFilter.java support/SimpleProtocolDecoderOutput.java
Date Wed, 06 Sep 2006 06:06:53 GMT
Author: trustin
Date: Tue Sep  5 23:06:53 2006
New Revision: 440626

URL: http://svn.apache.org/viewvc?view=rev&rev=440626
Log:
Fixed possible ClassCastException in ProtocolCodecFilter

Modified:
    directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java
    directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/support/SimpleProtocolDecoderOutput.java

Modified: directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java
URL: http://svn.apache.org/viewvc/directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java?view=diff&rev=440626&r1=440625&r2=440626
==============================================================================
--- directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java
(original)
+++ directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java
Tue Sep  5 23:06:53 2006
@@ -219,8 +219,10 @@
         try
         {
             encoder.encode( session, message, encoderOut );
-            
-            ((BaseIoSession)session).increaseWrittenMessages();
+            if( session instanceof BaseIoSession )
+            {
+                ( ( BaseIoSession ) session ).increaseWrittenMessages();
+            }
         }
         catch( Throwable t )
         {

Modified: directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/support/SimpleProtocolDecoderOutput.java
URL: http://svn.apache.org/viewvc/directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/support/SimpleProtocolDecoderOutput.java?view=diff&rev=440626&r1=440625&r2=440626
==============================================================================
--- directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/support/SimpleProtocolDecoderOutput.java
(original)
+++ directory/trunks/mina/core/src/main/java/org/apache/mina/filter/codec/support/SimpleProtocolDecoderOutput.java
Tue Sep  5 23:06:53 2006
@@ -49,7 +49,7 @@
         messageQueue.push( message );
         if( session instanceof BaseIoSession )
         {
-            ( (BaseIoSession) session ).increaseReadMessages();
+            ( ( BaseIoSession ) session ).increaseReadMessages();
         }
     }
 



Mime
View raw message