Replace pgs[id] with pgs.at(id) to prevent accidental auto-vivification

This commit is contained in:
Vitaliy Filippov
2021-02-28 19:36:59 +03:00
parent 7d49706c07
commit 6155b23a7e
4 changed files with 11 additions and 8 deletions
+1 -1
View File
@@ -95,7 +95,7 @@ void osd_t::handle_flush_op(bool rollback, pool_id_t pool_id, pg_num_t pg_num, p
{
// This flush batch is done
std::vector<osd_op_t*> continue_ops;
auto & pg = pgs[pg_id];
auto & pg = pgs.at(pg_id);
auto it = pg.flush_actions.begin(), prev_it = it;
auto erase_start = it;
while (1)