Skip to content

Commit

Permalink
Fix parallelism clean up issue
Browse files Browse the repository at this point in the history
  • Loading branch information
JC-comp committed Oct 22, 2023
1 parent 5a4a351 commit f86c4b9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/main.d
Original file line number Diff line number Diff line change
Expand Up @@ -1139,6 +1139,8 @@ extern(C) nothrow @nogc @system void exitHandler(int value) {
try {
assumeNoGC ( () {
log.log("Got termination signal, performing clean up");
// Wait for all parallel jobs that depend on the database to complete
taskPool.finish(true);
// was itemDb initialised?
if (itemDB.isDatabaseInitialised()) {
// Make sure the .wal file is incorporated into the main db before we exit
Expand Down

0 comments on commit f86c4b9

Please sign in to comment.