Skip to content
Snippets Groups Projects
Commit c0102b73 authored by Vladimir Davydov's avatar Vladimir Davydov
Browse files

box: don't destroy latch/fiber_cond that may have waiters at exit

fiber_cond_destroy() and latch_destroy() are no-op on release builds
while on debug builds they check that there is no fibers waiting on
the destroyed object. This results in the following assertion failures
occasionally hit by some tests:

  src/latch.h:81: latch_destroy: Assertion `l->owner == NULL' failed.
  src/fiber_cond.c:49: fiber_cond_destroy: Assertion `rlist_empty(&c->waiters)' failed.

We can't do anything about that, because the event loop isn't running at
exit and hence we can't stop those fibers. So let's not "destroy" those
global objects that may have waiters at exit, namely

  gc.latch
  ro_cond
  replicaset.applier.cond
parent b43c89ba
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment