Bug #80359
closedUndefined end() iterator in proc_master_log can cause pwlc values to be set incorrectly
0%
Description
In proc_master_log, we need to decide when to call consider_adjusting_pwlc(...). We do this by comparing the incoming log from a message against our own log. We use an iterator pointing at the end of the incoming log and compare it to our own log in various ways to determine if we need to adjust the pwlc values. For all non-empty cases, we were comparing olog.log.end()->version with p->version, where accessing olog.log.end() results in undefined behaviour (https://en.cppreference.com/cpp/container/list/end).
Fix created here: https://github.com/ceph/ceph/pull/71595. This fixes the issue by decrementing the iterator for these cases so we are pointing at the final element of the log instead of the end() iterator which is one past the end.
JB Updated by Jonathan Bailey 3 months ago
- Project changed from Ceph to RADOS
JB Updated by Jonathan Bailey 3 months ago
- Status changed from New to In Progress
- Assignee set to Jonathan Bailey
BS Updated by Bill Scales 3 months ago
- Backport set to tentacle umbrella
LF Updated by Laura Flores 3 months ago
PR has been added to a QA batch.
LF Updated by Laura Flores 2 months ago
- Status changed from In Progress to Duplicate
LF Updated by Laura Flores 2 months ago
- Is duplicate of Bug #79706: osd/PeeringState: fix proc_master_log divergence check vs olog.head added
UB Updated by Upkeep Bot 2 months ago
- Pull request ID deleted (
71595) - Upkeep Timestamp set to 2026-09-24T00:42:33+00:00