diff options
Diffstat (limited to 'cpp/src/Freeze/Util.h')
-rw-r--r-- | cpp/src/Freeze/Util.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/cpp/src/Freeze/Util.h b/cpp/src/Freeze/Util.h index caaf24bf229..1cef571bba1 100644 --- a/cpp/src/Freeze/Util.h +++ b/cpp/src/Freeze/Util.h @@ -48,11 +48,24 @@ initializeOutDbt(std::vector<Ice::Byte>& v, Dbt& dbt) dbt.set_flags(DB_DBT_USERMEM); } + +// +// Handles a Berkeley DB DbException by resizing the +// given key/value/dbt (when the exception's errno is +// DB_SMALL_BUFFER) or by throwing a +// Freeze::DatabaseException +// + +void +handleDbException(const DbException&, const char*, int); + void -handleMemoryException(const DbMemoryException&, Key&, Dbt&); +handleDbException(const DbException&, Key&, Dbt&, + const char*, int); void -handleMemoryException(const DbMemoryException&, Key&, Dbt&, Value&, Dbt&); +handleDbException(const DbException&, Key&, Dbt&, Value&, Dbt&, + const char*, int); } |