MCS: Use remote.h and cleanup header file inclusion
[remote/remote-mci.git] / libutil / error.h
blob283ea1b035554754cc7da5056ec38eec30aaf94c
1 #ifndef REMOTE_ERROR_H
2 #define REMOTE_ERROR_H
4 #include <exception>
5 #include <stdio.h>
7 namespace remote {
9 class error : public std::exception
11 public:
12 error(std::string message)
14 description = message;
17 error(int error, std::string message)
19 description = message + ": " + strerror(error);
22 ~error() throw ()
26 const char *what() const throw ()
28 return description.c_str();
31 private:
32 std::string description;
37 #endif