Skip to content

Commit

Permalink
Address review comment
Browse files Browse the repository at this point in the history
  • Loading branch information
kpamnany committed Sep 18, 2024
1 parent 0602dcc commit 3fe564d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/threading.c
Original file line number Diff line number Diff line change
Expand Up @@ -1035,8 +1035,13 @@ JL_DLLEXPORT int jl_heartbeat_resume(void)
if (uv_sem_trywait(&heartbeat_off_sem) != 0) {
return -1;
}

// reset state as we've been paused
n_hbs_missed = 0;
n_hbs_recvd = 0;
tasks_showed = 0;

// resume
heartbeat_enabled = 1;
uv_sem_post(&heartbeat_on_sem); // wake the heartbeat thread
return 0;
Expand Down

0 comments on commit 3fe564d

Please sign in to comment.