aboutsummaryrefslogtreecommitdiff
path: root/odb/exceptions.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-03-06 11:34:56 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-03-06 11:34:56 +0200
commitc2be6303f97e470960ee77805128c46d3ea5c102 (patch)
treef45e58c26c88d28fca9a2747fc4e4d4cdb4e0364 /odb/exceptions.cxx
parent3e34265af868388acde7ab2c198bf9f82775eba4 (diff)
Detect situations where session is required but not used
Throw session_required.
Diffstat (limited to 'odb/exceptions.cxx')
-rw-r--r--odb/exceptions.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/odb/exceptions.cxx b/odb/exceptions.cxx
index 9089a5b..b200843 100644
--- a/odb/exceptions.cxx
+++ b/odb/exceptions.cxx
@@ -46,6 +46,12 @@ namespace odb
return "session not in effect in this thread";
}
+ const char* session_required::
+ what () const throw ()
+ {
+ return "session required to load this object relationship";
+ }
+
const char* deadlock::
what () const throw ()
{