HomePhabricator

fix race that could fail to persist a ban
f4ac02ee7c65Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

fix race that could fail to persist a ban

DumpBanList currently does this:

  • with lock: take a copy of the banmap
  • perform I/O (write out the banmap)
  • with lock: mark the banmap non-dirty

If a new ban is added during the I/O operation, it may never be persisted to
disk.

Reorder operations so that the data to be persisted cannot be older than the
time at which the banmap was marked non-dirty.

Details

Provenance
Kaz Wesley <keziahw@gmail.com>Authored on Apr 27 2016, 16:26
deadalnixPushed on May 14 2017, 22:04
Parents
rABC08b37c5e06bf: Merge #7954: build: quiet annoying warnings without adding new ones
Branches
Unknown
Tags
Unknown

Event Timeline

Kaz Wesley <keziahw@gmail.com> committed rABCf4ac02ee7c65: fix race that could fail to persist a ban (authored by Kaz Wesley <keziahw@gmail.com>).Apr 27 2016, 16:41