Skip to content

Fixed a leak in NewReference.Move #1873

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

Merged
merged 2 commits into from
Jul 14, 2022
Merged

Conversation

lostmsu
Copy link
Member

@lostmsu lostmsu commented Jul 14, 2022

What does this implement/fix? Explain your changes.

NewReference.Move used to call NewReference constructor that increfs the handle. However, Move semantics must be of transferring the ownership: the reference count should stay, ownership transferred to the new instance.

Does this close any currently open issues?

#1872

Checklist

Check all those that are applicable and complete.

  • Make sure to include one or more tests for your change

@filmor filmor merged commit 9bb8fe6 into pythonnet:release Jul 14, 2022
@filmor
Copy link
Member

filmor commented Jul 14, 2022

Great, thanks!

@lostmsu lostmsu deleted the bugs/ctor-leak branch July 14, 2022 20:13
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