diff --git a/src/test/test_pg_chaos.cpp b/src/test/test_pg_chaos.cpp index d0c448cc..20d92bbb 100644 --- a/src/test/test_pg_chaos.cpp +++ b/src/test/test_pg_chaos.cpp @@ -3894,7 +3894,9 @@ void chaos_t::flush_recover_pending() if (!pg_active()) return; int obj = *it; - if (check_recovered(obj, "an outage")) + // A read racing a write in flight may see part of it (flushed in place + // under the read), so check the object only once nothing is in flight + if (!busy[obj] && check_recovered(obj, "an outage")) it = recover_pending.erase(it); else ++it;