From: Scott Cantor Date: Wed, 6 Jun 2007 16:13:25 +0000 (+0000) Subject: Set storage context for DOM constructed map. X-Git-Tag: 2.0-alpha1~5 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=shibboleth%2Fcpp-opensaml.git;a=commitdiff_plain;h=69538bbf41bf3d8394e12d5b148adb9615b22867 Set storage context for DOM constructed map. --- diff --git a/saml/binding/impl/ArtifactMap.cpp b/saml/binding/impl/ArtifactMap.cpp index 9d4e347..b8ecb22 100644 --- a/saml/binding/impl/ArtifactMap.cpp +++ b/saml/binding/impl/ArtifactMap.cpp @@ -141,7 +141,7 @@ XMLObject* ArtifactMappings::retrieveContent(const SAMLArtifact* artifact, const } ArtifactMap::ArtifactMap(xmltooling::StorageService* storage, const char* context, unsigned int artifactTTL) - : m_storage(storage), m_context(context ? context : "opensaml::ArtifactMap"), m_mappings(NULL), m_artifactTTL(artifactTTL) + : m_storage(storage), m_context((context && *context) ? context : "opensaml::ArtifactMap"), m_mappings(NULL), m_artifactTTL(artifactTTL) { if (!m_storage) m_mappings = new ArtifactMappings(); @@ -154,6 +154,8 @@ ArtifactMap::ArtifactMap(const DOMElement* e, xmltooling::StorageService* storag auto_ptr_char c(e->getAttributeNS(NULL, context)); if (c.get() && *c.get()) m_context = c.get(); + else + m_context = "opensaml::ArtifactMap"; const XMLCh* TTL = e->getAttributeNS(NULL, artifactTTL); if (TTL) {