summaryrefslogtreecommitdiff
path: root/libodbcpp/error.h
diff options
context:
space:
mode:
authorrandomdan <randomdan@localhost>2008-11-13 14:45:11 +0000
committerrandomdan <randomdan@localhost>2008-11-13 14:45:11 +0000
commitefd292508070835781a0d92448a3661279dfd307 (patch)
tree0d2592bacfdb0cd159ebc5780dd69f86cc893af0 /libodbcpp/error.h
parentFix the C++ template errors (diff)
downloadlibdbpp-odbc-efd292508070835781a0d92448a3661279dfd307.tar.bz2
libdbpp-odbc-efd292508070835781a0d92448a3661279dfd307.tar.xz
libdbpp-odbc-efd292508070835781a0d92448a3661279dfd307.zip
Lots of little fixes
Diffstat (limited to 'libodbcpp/error.h')
-rw-r--r--libodbcpp/error.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/libodbcpp/error.h b/libodbcpp/error.h
index f7c2958..f283a7c 100644
--- a/libodbcpp/error.h
+++ b/libodbcpp/error.h
@@ -2,14 +2,20 @@
#define ODBC_ERROR_H
#include <sql.h>
+#include <exception>
namespace ODBC {
- class Error {
+ class Error : public std::exception {
public:
Error(RETCODE err, SQLSMALLINT handletype, SQLHANDLE handle, char const * action, ...)
__attribute__((format(printf, 5, 6)));
Error(char const * action, ...)
__attribute__((format(printf, 2, 3)));
+ ~Error() throw();
+
+ const char * what() const throw();
+ private:
+ char * msg;
};
}