Skip to content

Conversation

@algebraic-dev
Copy link
Member

@algebraic-dev algebraic-dev commented Dec 5, 2025

This PR fixes a segmentation fault that was triggered when initializing a new timer and a reset was called at the same time.

@algebraic-dev algebraic-dev self-assigned this Dec 5, 2025
@github-actions github-actions bot added the toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN label Dec 5, 2025
@leanprover-community-bot
Copy link
Collaborator

Mathlib CI status (docs):

  • ❗ Batteries/Mathlib CI will not be attempted unless your PR branches off the nightly-with-mathlib branch. Try git rebase ab606ba7541e65dc1e7ba695a50772de9891f3d0 --onto dd28f005889dd2fcca6fe0638133de561a655ad1. You can force Mathlib CI using the force-mathlib-ci label. (2025-12-05 04:44:46)

@leanprover-bot
Copy link
Collaborator

Reference manual CI status:

  • ❗ Reference manual CI will not be attempted unless your PR branches off the nightly-with-manual branch. Try git rebase ab606ba7541e65dc1e7ba695a50772de9891f3d0 --onto d3dda9f6d4428a906c096067ecb75e432afc4615. You can force reference manual CI using the force-manual-ci label. (2025-12-05 04:44:47)

@TwoFX
Copy link
Member

TwoFX commented Dec 6, 2025

Is it possible to have a test for this?

@algebraic-dev
Copy link
Member Author

algebraic-dev commented Dec 6, 2025

It’s a data race between the next and cancel functions, when the next function needs to return a promise that is inside the timer structure. (outside of the libuv lock) but cancel is setting it to NULL at the same time. I don't think it's easy to test this.

@algebraic-dev algebraic-dev requested a review from TwoFX December 8, 2025 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog-library Library toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants