Bypass spurious warning
authorcantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Mon, 9 Jun 2003 05:25:08 +0000 (05:25 +0000)
committercantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Mon, 9 Jun 2003 05:25:08 +0000 (05:25 +0000)
git-svn-id: https://svn.middleware.georgetown.edu/cpp-sp/trunk@486 cb58f699-b61c-0410-a6fe-9272a202ed29

shib/AAP.cpp

index 6941a76..7cd128d 100644 (file)
@@ -252,10 +252,13 @@ bool AAP::accept(const XMLCh* name, const XMLCh* originSite, DOMElement* e)
     for (vector<pair<AttributeRule::value_type,xstring> >::const_iterator i=arule->second.m_anySiteRule.valueRules.begin();
             i!=arule->second.m_anySiteRule.valueRules.end(); i++)
     {
-        if (i->first==AttributeRule::literal && i->second==n->getNodeValue())
+        if (i->first==AttributeRule::literal)
         {
-            log.debug("any site, literal match");
-            return true;
+            if (i->second==n->getNodeValue())
+            {
+                log.debug("any site, literal match");
+                return true;
+            }
         }
         else if (i->first==AttributeRule::regexp)
         {
@@ -295,10 +298,13 @@ bool AAP::accept(const XMLCh* name, const XMLCh* originSite, DOMElement* e)
     for (vector<pair<AttributeRule::value_type,xstring> >::const_iterator j=srule->second.valueRules.begin();
             j!=srule->second.valueRules.end(); j++)
     {
-        if (j->first==AttributeRule::literal && j->second==n->getNodeValue())
+        if (j->first==AttributeRule::literal)
         {
-            log.debug("matching site, literal match");
-            return true;
+            if (j->second==n->getNodeValue())
+            {
+                log.debug("matching site, literal match");
+                return true;
+            }
         }
         else if (j->first==AttributeRule::regexp)
         {