mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-11-20 23:16:27 -05:00
_process_func contained two identical compare_exchange_weak loops for claiming a _remove_count decrement — one in the poison-pill handler and one after task completion. Duplicating the loop risks the two copies diverging during future edits and makes the function harder to follow. Extract the loop into _try_claim_removal() which returns true when a decrement is successfully claimed. Both call sites now delegate to the shared helper. The relaxed memory ordering rationale (the subsequent _remove_self acquires _threads_mutex, providing the happens-before with the scaling-side increment) is documented on the helper. No functional change. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| acutest | ||
| boost | ||
| CLI11 | ||
| fmt | ||
| khash | ||
| libfuse | ||
| nonstd | ||
| rapidhash | ||
| scope_guard | ||
| subprocess | ||