ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [03/50] [abbrv] ignite git commit: fixed https://issues.apache.org/jira/browse/IGNITE-2119
Date Fri, 11 Dec 2015 10:00:08 GMT
fixed https://issues.apache.org/jira/browse/IGNITE-2119


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/2e68a878
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/2e68a878
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/2e68a878

Branch: refs/heads/master
Commit: 2e68a87869bd9d854c3efbbb20a72aef7b44fd2a
Parents: 9012b39
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Thu Dec 10 16:00:35 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Thu Dec 10 16:00:35 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/internal/util/nio/GridNioServer.java   | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/2e68a878/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
b/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
index c0f5cfc..53cec84 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
@@ -876,24 +876,23 @@ public class GridNioServer<T> {
 
                 return;
             }
-            else if (cnt == 0 && !readBuf.hasRemaining())
-                return;
 
             if (log.isTraceEnabled())
                 log.trace("Bytes received [sockCh=" + sockCh + ", cnt=" + cnt + ']');
 
+            if (cnt == 0)
+                return;
+
             if (metricsLsnr != null)
                 metricsLsnr.onBytesReceived(cnt);
 
             ses.bytesReceived(cnt);
 
-            // Sets limit to current position and
-            // resets position to 0.
             readBuf.flip();
 
-            try {
-                assert readBuf.hasRemaining();
+            assert readBuf.hasRemaining();
 
+            try {
                 filterChain.onMessageReceived(ses, readBuf);
 
                 if (readBuf.hasRemaining())


Mime
View raw message