commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (NET-619) SubnetUtils creates a binary netmask in a bad way
Date Wed, 01 Mar 2017 16:14:45 GMT

    [ https://issues.apache.org/jira/browse/NET-619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15890458#comment-15890458
] 

Sebb commented on NET-619:
--------------------------

Whilst the original is not particularly clear, I'm not convinced that the suggested alternative
is clearer.
However it does avoid an explicit loop.

IMO the problem in both cases is a lack of explanatory comments.

> SubnetUtils creates a binary netmask in a bad way
> -------------------------------------------------
>
>                 Key: NET-619
>                 URL: https://issues.apache.org/jira/browse/NET-619
>             Project: Commons Net
>          Issue Type: Improvement
>            Reporter: Makoto Sakaguchi
>            Priority: Minor
>
> SubnetUtils runs a for-loop to create a binary netmask.
> However, the way has been difficult to understand the program.
> I suggest to replace with a bit-shift, and it has been made a poll request on GitHub.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message