diff options
author | Bernard Normier <bernard@zeroc.com> | 2007-11-19 16:13:05 -0500 |
---|---|---|
committer | Bernard Normier <bernard@zeroc.com> | 2007-11-19 16:13:05 -0500 |
commit | a9b2a73a6c8897e84e5e64ee8b41fe17b06d3f54 (patch) | |
tree | eb1216068d7e9be1c1039f13953b2101f00aa60f /cpp/src/Freeze/EvictorIteratorI.cpp | |
parent | Added IceSL makedist.py (diff) | |
download | ice-a9b2a73a6c8897e84e5e64ee8b41fe17b06d3f54.tar.bz2 ice-a9b2a73a6c8897e84e5e64ee8b41fe17b06d3f54.tar.xz ice-a9b2a73a6c8897e84e5e64ee8b41fe17b06d3f54.zip |
Fixed bug #2543
Diffstat (limited to 'cpp/src/Freeze/EvictorIteratorI.cpp')
-rw-r--r-- | cpp/src/Freeze/EvictorIteratorI.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cpp/src/Freeze/EvictorIteratorI.cpp b/cpp/src/Freeze/EvictorIteratorI.cpp index 401b17750fd..0ff5f418569 100644 --- a/cpp/src/Freeze/EvictorIteratorI.cpp +++ b/cpp/src/Freeze/EvictorIteratorI.cpp @@ -23,7 +23,7 @@ Freeze::EvictorIteratorI::EvictorIteratorI(ObjectStoreBase* store, const Transac _key(1024), _more(store != 0), _initialized(false), - _tx(tx == 0 ? 0 : tx->dbTxn()) + _tx(tx) { _batchIterator = _batch.end(); } @@ -74,6 +74,8 @@ Freeze::EvictorIteratorI::nextBatch() CommunicatorPtr communicator = _store->communicator(); + DbTxn* txn = _tx == 0 ? 0: _tx->dbTxn(); + try { for(;;) @@ -108,7 +110,7 @@ Freeze::EvictorIteratorI::nextBatch() dbKey.set_size(static_cast<u_int32_t>(firstKey.size())); } - _store->db()->cursor(_tx, &dbc, 0); + _store->db()->cursor(txn, &dbc, 0); bool done = false; do @@ -217,7 +219,7 @@ Freeze::EvictorIteratorI::nextBatch() } catch(const DbDeadlockException& dx) { - throw DeadlockException(__FILE__, __LINE__, dx.what()); + throw DeadlockException(__FILE__, __LINE__, dx.what(), _tx); } catch(const DbException& dx) { |