branch | no-netsession |
changeset 36 | 785d220fc6b7 |
child 38 | 4189b8bf3a5b |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/proto2/Error.hh Thu Nov 20 19:25:56 2008 +0000 @@ -0,0 +1,16 @@ +#ifndef ERROR_HH +#define ERROR_HH + +class Error : public std::exception { + private: + const char *message; + + public: + Error (const std::string &message) : message(message.c_str()) { } + + virtual const char* what() const throw() { + return message; + } +}; + +#endif /* ERROR_HH */