You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by isapir <gi...@git.apache.org> on 2017/10/07 17:46:54 UTC

[GitHub] tomcat pull request #77: Removed findbugs bad practice warnings by making cl...

GitHub user isapir opened a pull request:

    https://github.com/apache/tomcat/pull/77

    Removed findbugs bad practice warnings by making classes final

    CN org.apache.catalina.tribes.io.ChannelData.clone() does not call super.clone()
    CN org.apache.catalina.tribes.membership.Membership.clone() does not call super.clone()
    CN org.apache.catalina.tribes.tipis.AbstractReplicatedMap$MapMessage.clone() does not call super.clone()
    CN org.apache.catalina.util.URLEncoder.clone() does not call super.clone()

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/isapir/tomcat update-04

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/tomcat/pull/77.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #77
    
----
commit 99c1744f8040943cd48a3a5d81f69af477f1c651
Author: Igal Sapir <de...@21solutions.net>
Date:   2017-10-07T17:46:15Z

    Removed findbugs bad practice warnings by making classes final
    
    CN org.apache.catalina.tribes.io.ChannelData.clone() does not call super.clone()
    CN org.apache.catalina.tribes.membership.Membership.clone() does not call super.clone()
    CN org.apache.catalina.tribes.tipis.AbstractReplicatedMap$MapMessage.clone() does not call super.clone()
    CN org.apache.catalina.util.URLEncoder.clone() does not call super.clone()

----


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[GitHub] tomcat issue #77: Removed findbugs bad practice warnings by making classes f...

Posted by isapir <gi...@git.apache.org>.
Github user isapir commented on the issue:

    https://github.com/apache/tomcat/pull/77
  
    I actually started with using super.clone() but upon further research opted for marking the classes as `final`.  All the "best practices" advocates say to avoid using the faulty clone() method as described in Joshua Bloch's book _Effective Java_, and also described in articles online like http://www.artima.com/intv/bloch13.html
    
    I will refactor these to use `super.clone()`.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[GitHub] tomcat issue #77: Removed findbugs bad practice warnings by making classes f...

Posted by markt-asf <gi...@git.apache.org>.
Github user markt-asf commented on the issue:

    https://github.com/apache/tomcat/pull/77
  
    These have been resolved since this PR was opened.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[GitHub] tomcat pull request #77: Removed findbugs bad practice warnings by making cl...

Posted by markt-asf <gi...@git.apache.org>.
Github user markt-asf closed the pull request at:

    https://github.com/apache/tomcat/pull/77


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[GitHub] tomcat issue #77: Removed findbugs bad practice warnings by making classes f...

Posted by markt-asf <gi...@git.apache.org>.
Github user markt-asf commented on the issue:

    https://github.com/apache/tomcat/pull/77
  
    Making those classes final will cause problems if users have extended any of them. While that seems unlikely, experience suggests it has probably been done somewhere.  Is there any reason super.clone() can't be used instead for these?


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org