Fix for setAttribute method.
authorScott Cantor <cantor.2@osu.edu>
Mon, 19 Jun 2006 02:58:05 +0000 (02:58 +0000)
committerScott Cantor <cantor.2@osu.edu>
Mon, 19 Jun 2006 02:58:05 +0000 (02:58 +0000)
xmltooling/encryption/impl/EncryptionImpl.cpp

index 1f5c54a..39030a8 100644 (file)
@@ -297,10 +297,14 @@ namespace xmlencryption {
 
         void setAttribute(QName& qualifiedName, const XMLCh* value) {
             if (!qualifiedName.hasNamespaceURI()) {
-                if (XMLString::equals(qualifiedName.getLocalPart(),ID_ATTRIB_NAME))
+                if (XMLString::equals(qualifiedName.getLocalPart(),ID_ATTRIB_NAME)) {
                     setId(value);
-                else if (XMLString::equals(qualifiedName.getLocalPart(),TARGET_ATTRIB_NAME))
+                    return;
+                }
+                else if (XMLString::equals(qualifiedName.getLocalPart(),TARGET_ATTRIB_NAME)) {
                     setTarget(value);
+                    return;
+                }
             }
             AbstractAttributeExtensibleXMLObject::setAttribute(qualifiedName, value);
         }