harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r418979 - /incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java
Date Tue, 04 Jul 2006 11:01:23 GMT
Author: tellison
Date: Tue Jul  4 04:01:23 2006
New Revision: 418979

URL: http://svn.apache.org/viewvc?rev=418979&view=rev
Log:
Apply fix HARMONY-740 ([classlib][nio] Remove synchronization related FIXMEs in java.nio.MappedByteBuffer)

Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java?rev=418979&r1=418978&r2=418979&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/java/nio/MappedByteBufferAdapter.java
Tue Jul  4 04:01:23 2006
@@ -109,10 +109,6 @@
 		return this.wrapped.get(index);
 	}
 
-	// FIXME Need synchronization as far as the update of this.position is
-	// concerned of the following methods? Spec does not say whether
-	// MappedByteBuffer
-	// is thread safe. It is the decision we should make.
 	public char getChar() {
 		int newPosition = this.position + CHAR_SIZE;
 		if (newPosition > this.limit) {
@@ -214,7 +210,6 @@
 		return this.wrapped.order(byteOrder);
 	}
 
-	// FIXME: This method also has the synchronization problem.
 	public ByteBuffer put(byte b) {
 		if (this.position == this.limit) {
 			throw new BufferOverflowException();
@@ -252,7 +247,6 @@
 
 	public ByteBuffer putDouble(double value) {
 		int newPosition = this.position + DOUBLE_SIZE;
-		// FIXME: Does this need synchronization?
 		if (newPosition > this.limit) {
 			throw new BufferOverflowException();
 		}
@@ -268,7 +262,6 @@
 
 	public ByteBuffer putFloat(float value) {
 		int newPosition = this.position + FLOAT_SIZE;
-		// FIXME:Synchronization problem
 		if (newPosition > this.limit) {
 			throw new BufferOverflowException();
 		}
@@ -289,7 +282,6 @@
 
 	public ByteBuffer putInt(int value) {
 		int newPosition = this.position + INTEGER_SIZE;
-		// FIXME: Synchronization
 		if (newPosition > this.limit) {
 			throw new BufferOverflowException();
 		}
@@ -304,7 +296,6 @@
 	}
 
 	public ByteBuffer putLong(long value) {
-		// FIXME: Synchronization
 		int newPosition = this.position + LONG_SIZE;
 		if (newPosition > this.limit) {
 			throw new BufferOverflowException();
@@ -320,7 +311,6 @@
 	}
 
 	public ByteBuffer putShort(short value) {
-		// FIXME: Synchronization
 		int newPosition = this.position + SHORT_SIZE;
 		if (newPosition > this.limit) {
 			throw new BufferOverflowException();



Mime
View raw message