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

Cleaner threadPool initialization #3288

Merged
merged 1 commit into from
Oct 15, 2022
Merged

Cleaner threadPool initialization #3288

merged 1 commit into from
Oct 15, 2022

Conversation

Cyan4973
Copy link
Contributor

@Cyan4973 Cyan4973 commented Oct 13, 2022

This is the first part of #3121, which is correct even though it failed at its intended objective to fix #3119.

This PR just ensures that the queue and the pool are cleanly set to zero,
so that no uninitialized noise can influence the behavior.
These memory areas are small, and employed in a context of much higher load (multi-threading, context-switching, etc.),
so there is no expectation of performance impact.

It just turns out that #3119 is more likely triggered by a race condition than a side effect of uninitialization.
Yet, the patch looks useful, as it removes a potential source of random issue considered during the investigation for #3119.

fix segfault error when running zstreamtest with MALLOC_PERTURB_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

"./zstreamtest --newapi" test case fails on Windows
2 participants