Commit 383d8952 authored by Yoni Fogel's avatar Yoni Fogel

Addresses #523

Cleaned up iteration code based on code review by Zardosht.

git-svn-id: file:///svn/tokudb@2794 c7de825b-a66e-492c-adef-691d508d4ae1
parent af4fc44e
......@@ -396,11 +396,12 @@ int toku_rt_next (toku_range_tree* range_tree, toku_range* out_range, BOOL* elem
if (r != 0) { goto cleanup; }
}
range_tree->i.iter_is_valid = ret_range != NULL;
*elem_found = range_tree->i.iter_is_valid;
*elem_found = ret_range != NULL;
range_tree->i.iter_is_valid = ret_range != NULL;
if (*elem_found) { *out_range = *ret_range; }
r = 0;
cleanup:
if (r!=0) { toku_rt_invalidate_iteration(range_tree); }
return r;
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment