Fix ongoing unchecked cleanup (#2342)

This commit is contained in:
Guilherme Lawless 2019-10-15 14:27:02 +01:00 committed by GitHub
commit 0b18a4b9db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 2 deletions

View file

@ -259,7 +259,10 @@ void nano::bootstrap_attempt::run ()
lazy_run ();
lock.lock ();
}
node->unchecked_cleanup ();
if (!stopped)
{
node->unchecked_cleanup ();
}
}
stopped = true;
condition.notify_all ();

View file

@ -651,7 +651,7 @@ void nano::node::start ()
{
ongoing_bootstrap ();
}
else if (!flags.disable_unchecked_cleanup)
if (!flags.disable_unchecked_cleanup)
{
auto this_l (shared ());
worker.push_task ([this_l]() {