Skip to content

Fix startup crash due to int overflow on 32-bit architectures - #6

Open
ivorget wants to merge 1 commit into
die-net:mainfrom
ivorget:main
Open

Fix startup crash due to int overflow on 32-bit architectures#6
ivorget wants to merge 1 commit into
die-net:mainfrom
ivorget:main

Conversation

@ivorget

@ivorget ivorget commented Jul 28, 2026

Copy link
Copy Markdown

period and timeSlice are 64-bit counts of nanoseconds so were causing overflow and a subsequent crash if they were > ~2.1s when they were being converted to int on 32-bit architecture like ARM where int is 32-bit. Fixed by deferring conversion to int until after the calculation.

Defer conversion to int until after the calculation to avoid overflow on 32-bit architectures.
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.

1 participant