directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r169263 - /directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java
Date Mon, 09 May 2005 09:55:23 GMT
Author: trustin
Date: Mon May  9 02:55:22 2005
New Revision: 169263

URL: http://svn.apache.org/viewcvs?rev=169263&view=rev
Log:
Moved buffer initialization code fragments to init()

Modified:
    directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java

Modified: directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java
URL: http://svn.apache.org/viewcvs/directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java?rev=169263&r1=169262&r2=169263&view=diff
==============================================================================
--- directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java
(original)
+++ directory/network/branches/api_integration/src/java/org/apache/mina/common/ByteBuffer.java
Mon May  9 02:55:22 2005
@@ -200,8 +200,6 @@
                            java.nio.ByteBuffer.allocate( MINIMUM_CAPACITY << idx );
         }
         
-        buf.clear();
-        buf.order( ByteOrder.BIG_ENDIAN );
         return buf;
     }
     
@@ -532,6 +530,8 @@
         private synchronized void init( java.nio.ByteBuffer buf )
         {
             this.buf = buf;
+            buf.clear();
+            buf.order( ByteOrder.BIG_ENDIAN );
             autoExpand = false;
             refCount = 1;
         }



Mime
View raw message