Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
osd/PrimaryLogPG: do not use approx_size() for log trimming
There might be holes on log versions, thus the approx_size() should (almost) always overestimate the actual number of log entries. As a result, we might be at the risk of accessing violation while searching for the oldest log entry to keep in the log list later. Fix the above problem by counting the precise number of current log entries instead. Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
- Loading branch information