You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mina.apache.org by tr...@apache.org on 2007/11/05 17:06:04 UTC
svn commit: r592056 -
/mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java
Author: trustin
Date: Mon Nov 5 08:06:03 2007
New Revision: 592056
URL: http://svn.apache.org/viewvc?rev=592056&view=rev
Log:
Fixed a bug where AbstractIoBuffer.isDerived() returns a wrong value.
Modified:
mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java
Modified: mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java
URL: http://svn.apache.org/viewvc/mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java?rev=592056&r1=592055&r2=592056&view=diff
==============================================================================
--- mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java (original)
+++ mina/trunk/core/src/main/java/org/apache/mina/common/AbstractIoBuffer.java Mon Nov 5 08:06:03 2007
@@ -41,8 +41,8 @@
* @see IoBufferAllocator
*/
public abstract class AbstractIoBuffer extends IoBuffer {
+ private final boolean derived;
private boolean autoExpand;
-
private boolean autoExpandAllowed = true;
/**
@@ -51,12 +51,9 @@
*/
private int mark = -1;
- protected AbstractIoBuffer() {
- this(true);
- }
-
protected AbstractIoBuffer(boolean autoExpandAllowed) {
this.autoExpandAllowed = autoExpandAllowed;
+ this.derived = !autoExpandAllowed;
}
@Override
@@ -108,7 +105,7 @@
@Override
public boolean isDerived() {
- return !autoExpandAllowed;
+ return derived;
}
@Override