ShibTargetException needs copy ctor like elf needs food. Badly.
authorcantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Wed, 3 Dec 2003 06:33:29 +0000 (06:33 +0000)
committercantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Wed, 3 Dec 2003 06:33:29 +0000 (06:33 +0000)
git-svn-id: https://svn.middleware.georgetown.edu/cpp-sp/trunk@757 cb58f699-b61c-0410-a6fe-9272a202ed29

shib-target/shib-target.h

index 7e5fa71..86a3147 100644 (file)
@@ -224,10 +224,13 @@ namespace shibtarget {
   {
   public:
     explicit ShibTargetException() : m_origin(NULL), m_code(SHIBRPC_OK) {}
-    explicit ShibTargetException(ShibRpcStatus code, const char* msg, const XMLCh* origin = NULL) : m_code(code)
-    { if (msg) m_msg=msg; m_origin = XMLString::replicate(origin); }
-    explicit ShibTargetException(ShibRpcStatus code, const std::string& msg, const XMLCh* origin = NULL) : m_msg(msg)
-       { m_code=code; m_origin = XMLString::replicate(origin); }
+    explicit ShibTargetException(ShibRpcStatus code, const char* msg, const XMLCh* origin = NULL)
+        : m_code(code), m_origin(XMLString::replicate(origin)) { if (msg) m_msg=msg; }
+    explicit ShibTargetException(ShibRpcStatus code, const std::string& msg, const XMLCh* origin = NULL)
+        : m_code(code), m_msg(msg), m_origin(XMLString::replicate(origin)) {}
+    ShibTargetException(const ShibTargetException& src)
+        : m_code(src.m_code), m_msg(src.m_msg), m_origin(XMLString::replicate(src.m_origin)) {}
+    
     virtual ~ShibTargetException() throw () { if (m_origin) XMLString::release(&m_origin); }
     virtual const char* what() const throw () { return (m_msg.c_str()); }
     virtual ShibRpcStatus which() const throw () { return (m_code); }