src/java.net.http/share/classes/jdk/internal/net/http/WindowController.java
branchhttp-client-branch
changeset 56101 983e338eeb50
parent 56092 fd85b2bf2b0d
child 56227 278e1c6c3e99
--- a/src/java.net.http/share/classes/jdk/internal/net/http/WindowController.java	Fri Feb 09 15:22:31 2018 +0000
+++ b/src/java.net.http/share/classes/jdk/internal/net/http/WindowController.java	Fri Feb 09 18:50:31 2018 +0000
@@ -102,7 +102,7 @@
             // Odd stream numbers (client streams) should have been registered.
             // Even stream numbers (server streams - aka Push Streams) should
             // not be registered
-            final boolean isClientStream = (streamid % 2) == 1;
+            final boolean isClientStream = (streamid & 0x1) == 1;
             if (old == null && isClientStream) {
                 throw new InternalError("Expected entry for streamid: " + streamid);
             } else if (old != null && !isClientStream) {