[cpp-sp] 03/03: Extend plugin exception message.

Codeberg noreply at shibboleth.net
Thu May 28 18:46:40 UTC 2026


This is an automated email from the git hooks/post-receive script.

codeberg pushed a commit to branch main
in repository cpp-sp.

View the commit online:
https://codeberg.org/Shibboleth/cpp-sp/commit/d73ffe510085f0fe5a57860cce38d84bc1be87d6

commit d73ffe510085f0fe5a57860cce38d84bc1be87d6
Author: Scott Cantor <scott at restingparrotsoftware.com>
AuthorDate: Thu May 28 14:46:07 2026 -0400

    Extend plugin exception message.
---
 shibsp/util/PluginManager.h | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/shibsp/util/PluginManager.h b/shibsp/util/PluginManager.h
index f7fd7b12..b8c250b5 100644
--- a/shibsp/util/PluginManager.h
+++ b/shibsp/util/PluginManager.h
@@ -92,11 +92,15 @@ namespace shibsp {
         T* newPlugin(const Key& type, const Params& p, bool deprecationSupport) const {
             typename std::map<Key, typename PluginManager::Factory*>::const_iterator i=m_map.find(type);
             if (i==m_map.end())
-                throw std::invalid_argument("Unknown " + m_componentType + " plugin type.");
+                throw std::invalid_argument("Unknown " + m_componentType + " plugin type: " + keyToString(type));
             return i->second(p, deprecationSupport);
         }
         
     private:
+        std::string keyToString(const Key& key) const {
+            return key;
+        }
+
         std::string m_componentType;
         std::map<Key, typename PluginManager::Factory*> m_map;
     };

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list