From 46ebe94ef3d1bac93af32021301e7fb78cecd646 Mon Sep 17 00:00:00 2001 From: cantor Date: Sat, 26 May 2007 23:09:32 +0000 Subject: [PATCH] Fix bug when sending requests. git-svn-id: https://svn.middleware.georgetown.edu/cpp-opensaml2/trunk@262 fb386ef7-a10c-0410-8ebf-fd3f8e989ab0 --- saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp b/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp index a7d7500..49c424f 100644 --- a/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp +++ b/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp @@ -121,10 +121,11 @@ long SAML2ArtifactEncoder::encode( StatusResponseType* response = NULL; RequestAbstractType* request = dynamic_cast(xmlObject); - if (!request) + if (!request) { response = dynamic_cast(xmlObject); - if (!response) - throw BindingException("XML content for SAML 2.0 HTTP-Artifact Encoder must be a SAML 2.0 protocol message."); + if (!response) + throw BindingException("XML content for SAML 2.0 HTTP-Artifact Encoder must be a SAML 2.0 protocol message."); + } ArtifactMap* mapper = SAMLConfig::getConfig().getArtifactMap(); if (!mapper) -- 2.1.4