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 a memory leak in WindowsThread #3542

Closed
wants to merge 1 commit into from

Conversation

yuslepukhin
Copy link
Contributor

@yuslepukhin yuslepukhin commented Feb 26, 2018

_endthreadex does not return and thus objects
for stack destructors do not run. This creates a memory leak.
We remove the calls since _enthreadex called automatically after the
threadproc returns i.e. thread exits.

  for stack destructors do not run. This creates a memory leak.
  We remove the calls since it is called automatically after the
  threadproc returns i.e. thread exits.
@yuslepukhin
Copy link
Contributor Author

Cc @gfosco @siying @ajkr

Copy link
Contributor

@facebook-github-bot facebook-github-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ajkr has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

Copy link
Contributor

@facebook-github-bot facebook-github-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ajkr is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@yuslepukhin yuslepukhin deleted the winthread_memleak branch February 26, 2018 21:51
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.

None yet

2 participants