You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2020/01/12 18:36:31 UTC

[GitHub] [netbeans] lbruun commented on a change in pull request #1765: Tests in core network module

lbruun commented on a change in pull request #1765: Tests in core network module
URL: https://github.com/apache/netbeans/pull/1765#discussion_r365602049
 
 

 ##########
 File path: platform/core.network/src/org/netbeans/core/network/utils/LocalAddressUtils.java
 ##########
 @@ -92,29 +92,47 @@
     
     
     // 8.8.8.8  -- which incidentially is Google's DNS server, but we don't ever connect
-    private static final byte[] SOMEADDR_IPV4_RAW = new byte[]{
-        (byte)0x80, (byte)0x80, (byte)0x80, (byte)0x80, (byte)0x80, (byte)0x80, (byte)0x80, (byte)0x80};
+    private static final byte[] SOMEADDR_IPV4_RAW = new byte[]{0x08, 0x08, 0x08, 0x08};
 
 
 Review comment:
   @blackleg Thanks. It should of course have been a 4-byte array from the beginning. Too much cut'n paste. I think the correct solution from my part would have been to re-throw as a `RuntimeException` instead of a stupid remark "cannot happen by definition", which is strictly speaking true, but only if one doesn't screw up the array length. :-)
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists