You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2021/08/21 21:20:23 UTC
[tomcat] branch 8.5.x updated: Remove unnecessary finalize() method
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/8.5.x by this push:
new c3b1f5a Remove unnecessary finalize() method
c3b1f5a is described below
commit c3b1f5ae9a6b51703cbd17fbd389594f10914200
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Sat Aug 21 22:19:30 2021 +0100
Remove unnecessary finalize() method
If channel in non-null then it will retain a reference to the
AbstractReplicatedMap so it won;t be eligible for GC and finalize() will
never be called.
If channel is null then finalize isn;t required as there are no
references to clean up.
---
java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java b/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
index acdffb8..9d6b877 100644
--- a/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
+++ b/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
@@ -396,15 +396,6 @@ public abstract class AbstractReplicatedMap<K,V>
}
@Override
- public void finalize() throws Throwable {
- try {
- breakdown();
- } finally {
- super.finalize();
- }
- }
-
- @Override
public int hashCode() {
return Arrays.hashCode(this.mapContextName);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org