Avoids a race where chainStateFlushed could be called before rescanning began, yet rescan gets interrupted or fails
Followup for #24984 avoiding a race between registering and setting the flag.
Avoids a race where chainStateFlushed could be called before rescanning began, yet rescan gets interrupted or fails
Code Review ACK ba10b90915dae6a802ecb0f80f72a1a9ea5a4c67
I agree that this is avoids the possibility of a race.
ACK ba10b90915dae6a802ecb0f80f72a1a9ea5a4c67