diff --git a/src/util/ranges_set.cpp b/src/util/ranges_set.cpp index 615f977e99..f4ff5a2ca5 100644 --- a/src/util/ranges_set.cpp +++ b/src/util/ranges_set.cpp @@ -37,7 +37,7 @@ bool CRangesSet::Add(uint64_t value) if (next != ranges.end()) { if (next->begin == value + 1) { new_range.end = next->end; - it = ranges.erase(next); + ranges.erase(next); } } const auto ret = ranges.insert(new_range);