aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/utils/exceptn.h
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-05-30 08:09:19 -0400
committerJack Lloyd <[email protected]>2019-05-30 08:09:40 -0400
commit7ced8ecadfb2e5059b371e4c6b4a54b1dc92b6b9 (patch)
treeb2cae2ba91a5920b1d82cb96fa62da321f85321c /src/lib/utils/exceptn.h
parent2641a6b5332226f6bc4b1ae605ec948086e2969e (diff)
Revert part of #1744 making Exception constructors protected
This broke SoftHSM build
Diffstat (limited to 'src/lib/utils/exceptn.h')
-rw-r--r--src/lib/utils/exceptn.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/lib/utils/exceptn.h b/src/lib/utils/exceptn.h
index 0de17f6f3..61e7c7c1f 100644
--- a/src/lib/utils/exceptn.h
+++ b/src/lib/utils/exceptn.h
@@ -109,9 +109,19 @@ class BOTAN_PUBLIC_API(2,0) Exception : public std::exception
*/
virtual int error_code() const noexcept { return 0; }
- protected:
+ /**
+ * Avoid throwing base Exception, use a subclass
+ */
explicit Exception(const std::string& msg);
+
+ /**
+ * Avoid throwing base Exception, use a subclass
+ */
Exception(const char* prefix, const std::string& msg);
+
+ /**
+ * Avoid throwing base Exception, use a subclass
+ */
Exception(const std::string& msg, const std::exception& e);
private: