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

Fix crash in static variable deconstructor #238

Merged
merged 5 commits into from
Dec 25, 2023
Merged

Fix crash in static variable deconstructor #238

merged 5 commits into from
Dec 25, 2023

Conversation

Binyang2014
Copy link
Contributor

@Binyang2014 Binyang2014 commented Dec 22, 2023

According to https://en.cppreference.com/w/cpp/utility/program/exit
The last destructor for thread-local objects is [sequenced-before](https://en.cppreference.com/w/cpp/language/eval_order) the first destructor for a static object.
Change the code to avoid this case.

@chhwang chhwang enabled auto-merge (squash) December 24, 2023 16:40
@chhwang chhwang merged commit e7d3e2d into main Dec 25, 2023
15 checks passed
@chhwang chhwang deleted the binyli/update branch December 25, 2023 14:01
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