summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathon Jongsma <jonathon.jongsma@collabora.co.uk>2008-08-11 16:39:02 -0500
committerJonathon Jongsma <jonathon.jongsma@collabora.co.uk>2008-08-11 16:39:02 -0500
commit525574a514087d2e0c564a8d5275978ee0e96328 (patch)
treef06cf918adcea4435fce07e8a2774cfb513994fa
parent064242b819a9de11a7a8c646088fc77899098ea6 (diff)
Add ability to get the error code from a Cairo::logic_error exception
New API: Cairo::logic_error::get_status()
-rw-r--r--cairomm/exception.cc5
-rw-r--r--cairomm/exception.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/cairomm/exception.cc b/cairomm/exception.cc
index e389151..87972ae 100644
--- a/cairomm/exception.cc
+++ b/cairomm/exception.cc
@@ -37,6 +37,11 @@ logic_error::logic_error(ErrorStatus status)
logic_error::~logic_error() throw()
{}
+ErrorStatus logic_error::get_status() const
+{
+ return m_status;
+}
+
/*
const char* logic_error::what() const throw()
{
diff --git a/cairomm/exception.h b/cairomm/exception.h
index 6205a84..65d4e37 100644
--- a/cairomm/exception.h
+++ b/cairomm/exception.h
@@ -34,6 +34,7 @@ public:
virtual ~logic_error() throw();
//virtual const char* what() const throw();
+ ErrorStatus get_status() const;
private:
ErrorStatus m_status;