harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ghar...@apache.org
Subject svn commit: r421863 - /incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java
Date Fri, 14 Jul 2006 10:43:34 GMT
Author: gharley
Date: Fri Jul 14 03:43:32 2006
New Revision: 421863

URL: http://svn.apache.org/viewvc?rev=421863&view=rev
Log:
HARMONY 860 : [nio] Remove some unnecessary code and a FIXME from o.a.h.nio.internal.DatagramChannelImpl

Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java?rev=421863&r1=421862&r2=421863&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java
Fri Jul 14 03:43:32 2006
@@ -231,18 +231,6 @@
         try {
             begin();
 
-            // // FIXME donot peek at time,see if can improve
-            // DatagramPacket peekPack = new DatagramPacket(new byte[1], 1);
-            // synchronized (dataLock) {
-            // networkSystem.receiveDatagram(fd, peekPack, peekPack.getData(),
-            // peekPack.getOffset(), peekPack.getLength(),
-            // isBlocking() ? 0 : DEFAULT_TIMEOUT, true);
-            // }
-            // if (null == peekPack.getAddress()) {
-            // // if no new packet peeked
-            // return null;
-            // }
-
             // receive real data packet, (not peek)
             synchronized (readLock) {
                 boolean loop = isBlocking();
@@ -490,9 +478,6 @@
         synchronized (writeLock) {
             int count = 0;
             for (int val = offset; val < length; val++) {
-                // source buffer must be not null
-                checkNotNull(sources[val]);
-                // add all to avoid bugs in Linux
                 count = count + sources[val].remaining();
             }
             ByteBuffer writeBuf = ByteBuffer.allocate(count);



Mime
View raw message