diff options
| author | Carl Hetherington <cth@carlh.net> | 2018-07-07 19:35:42 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2018-07-07 19:35:42 +0100 |
| commit | 5c9e39df078aab9f03ae186d0758d4d710f90bab (patch) | |
| tree | 24ba2ec0e0d1e0f55411efed26396ad93f6879a0 /src/lib/exceptions.h | |
| parent | 173fc4c4ca837cbea881efc361604b82806a1807 (diff) | |
Give better errors when incorrect KDMs are used (#1326).
Diffstat (limited to 'src/lib/exceptions.h')
| -rw-r--r-- | src/lib/exceptions.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/src/lib/exceptions.h b/src/lib/exceptions.h index 5efb045b7..7220af35f 100644 --- a/src/lib/exceptions.h +++ b/src/lib/exceptions.h @@ -192,9 +192,19 @@ public: class KDMError : public std::runtime_error { public: - explicit KDMError (std::string s) - : std::runtime_error (s) - {} + KDMError (std::string s, std::string d); + + std::string summary () const { + return _summary; + } + + std::string detail () const { + return _detail; + } + +private: + std::string _summary; + std::string _detail; }; /** @class PixelFormatError |
