summaryrefslogtreecommitdiff
path: root/cpp/src/Freeze/EvictorIteratorI.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Freeze/EvictorIteratorI.cpp')
-rw-r--r--cpp/src/Freeze/EvictorIteratorI.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/cpp/src/Freeze/EvictorIteratorI.cpp b/cpp/src/Freeze/EvictorIteratorI.cpp
index c82b9eb4af8..d85c1fffe46 100644
--- a/cpp/src/Freeze/EvictorIteratorI.cpp
+++ b/cpp/src/Freeze/EvictorIteratorI.cpp
@@ -121,6 +121,12 @@ Freeze::EvictorIteratorI::nextBatch()
{
try
{
+ //
+ // It is critical to set key size to key capacity before the
+ // get, as a resize that increases the size inserts 0
+ //
+ _key.resize(_key.capacity());
+
_more = (dbc->get(&dbKey, &dbValue, flags) == 0);
if(_more)
{