From c883d0ba2f4450f35de6767355555fa83e6262ea Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 20 Aug 2010 10:23:55 +0200 Subject: Add deadlock exception --- odb/exceptions.hxx | 10 ++++------ odb/transaction.cxx | 3 +-- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/odb/exceptions.hxx b/odb/exceptions.hxx index b677503..13603be 100644 --- a/odb/exceptions.hxx +++ b/odb/exceptions.hxx @@ -10,24 +10,22 @@ namespace odb { - // nested_transaction - // struct already_in_transaction: odb::exception { }; - // no_transaction - // struct not_in_transaction: odb::exception { }; - // finilized_transaction - // struct transaction_already_finilized: odb::exception { }; + struct deadlock: odb::exception + { + }; + struct object_not_persistent: odb::exception { }; diff --git a/odb/transaction.cxx b/odb/transaction.cxx index 4fc730a..f9883b6 100644 --- a/odb/transaction.cxx +++ b/odb/transaction.cxx @@ -34,9 +34,8 @@ namespace odb { rollback (); } - catch (const database_exception&) + catch (...) { - // Ignore it. } } -- cgit v1.1