Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added fix for Instant::now() subtraction overflow #18

Merged
merged 1 commit into from
Jun 24, 2024

Conversation

RealAstolfo
Copy link

under the case that an individual runs a piece of software depending on this crate, the runtime will panic due to the Instant being smaller than the duration since the UNIX epoch.

You can reproduce this bug by simply restarting your PC (whether its linux or windows, i observed it occurring on both) and then trying to run an application depending on this crate.

under the case that an individual runs a piece of software depending on
this crate, the runtime will panic due to the Instant being smaller than
the durection since the UNIX epoch
@Nuhvi
Copy link
Collaborator

Nuhvi commented Jun 24, 2024

@RealAstolfo thanks a lot, very interesting edge case. I definitely should be careful with OS time.

@Nuhvi Nuhvi merged commit d5e9804 into pubky:main Jun 24, 2024
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants