You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by ca...@apache.org on 2005/07/22 20:08:17 UTC
cvs commit: logging-log4j/src/java/org/apache/log4j CategoryKey.java
carnold 2005/07/22 11:08:17
Modified: src/java/org/apache/log4j CategoryKey.java
Log:
Bug 35052: Problem with String.intern() in CategoryKey
Revision Changes Path
1.6 +2 -2 logging-log4j/src/java/org/apache/log4j/CategoryKey.java
Index: CategoryKey.java
===================================================================
RCS file: /home/cvs/logging-log4j/src/java/org/apache/log4j/CategoryKey.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- CategoryKey.java 27 Feb 2004 16:47:28 -0000 1.5
+++ CategoryKey.java 22 Jul 2005 18:08:17 -0000 1.6
@@ -26,7 +26,7 @@
int hashCache;
CategoryKey(String name) {
- this.name = name.intern();
+ this.name = name;
hashCache = name.hashCode();
}
@@ -40,7 +40,7 @@
}
if ((rArg != null) && (CategoryKey.class == rArg.getClass())) {
- return name == ((CategoryKey) rArg).name;
+ return name.equals(((CategoryKey) rArg).name);
} else {
return false;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org