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

C extension - Fix multiple reference leaks #42

Closed
wants to merge 1 commit into from

Conversation

vtermanis
Copy link

@vtermanis vtermanis commented May 12, 2018

After additional testing (of #41), I found more reference leaks / unnecessary increments:

  • exception attribute names (3x string)
  • True, False & None reference count increases
  • Removed redundant code & comment from MySQL_connected
  • MySQL_init & MySQL_connect leaks (charset)

See this gist for script used to track the leaks, together with before/after output.

Note: There might well be more leaks in the functions I have examined as well as in the module itself which could contribute to significant leaks in long-running Python processes utilising this library.

- exception attribute names (3x string)
- True, False & None reference count increases
- Removed redundant code & comment from MySQL_connected
- MySQL_init & MySQL_connect leaks (charset)
@vtermanis vtermanis changed the title Fix multiple reference leaks C extension - Fix multiple reference leaks May 12, 2018
@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Please confirm this code is submitted under the terms of the OCA (Oracle's Contribution Agreement) you have previously signed by cutting and pasting the following text as a comment:
"I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it."
Thanks

@vtermanis
Copy link
Author

I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

@mysql-oca-bot
Copy link

Hi, thank you for your contribution. Your code has been assigned to an internal queue. Please follow
bug http://bugs.mysql.com/bug.php?id=90862 for updates.
Thanks

@vtermanis vtermanis deleted the reference_leak_reduction branch June 14, 2018 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants