[java-opensaml COMMIT] /trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java
noreply at shibboleth.net
noreply at shibboleth.net
Wed Oct 23 20:27:20 EDT 2013
Author: putmanb
Date: Wed Oct 23 20:27:20 2013
New Revision: 3482
URL: http://svn.shibboleth.net/view/java-opensaml?rev=3482&view=rev
Log:
JXT-103: XMLTooling failed to pass veracode due Use of Wrong Operator in String Comparison (CWE ID 597).
And also port forward to v3.
Modified:
trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java
Modified: trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java
URL: http://svn.shibboleth.net/view/java-opensaml/trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java?rev=3482&r1=3481&r2=3482&view=diff
==============================================================================
--- trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java (original)
+++ trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java Wed Oct 23 20:27:20 2013
@@ -87,7 +87,7 @@
public String put(QName attributeName, String value) {
Constraint.isNotNull(attributeName, "Attribute name cannot be null");
String oldValue = get(attributeName);
- if (value != oldValue) {
+ if (!Objects.equal(value, oldValue)) {
releaseDOM();
attributes.put(attributeName, value);
if (isIDAttribute(attributeName) || XMLObjectProviderRegistrySupport.isIDAttribute(attributeName)) {
More information about the commits
mailing list