Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix Cairo memleak #5372

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 1 commit into from
Nov 2, 2015
Merged

Fix Cairo memleak #5372

merged 1 commit into from
Nov 2, 2015

Conversation

QuLogic
Copy link
Member

@QuLogic QuLogic commented Oct 31, 2015

Thanks to #5360, you can see a small memleak with the Cairo backend, apparently only 26.4889 bytes/loop. After fixing the leak, it's -0.7111 bytes/loop (aka 0).

The input buffer is copied internally when PyByteArray_FromStringAndSize
is called, so it doesn't need to stay around.
@QuLogic
Copy link
Member Author

QuLogic commented Oct 31, 2015

Also, cc @mdboom who added this bit in #4163.

@jkseppan
Copy link
Member

Looks correct to me, since PyByteArray_FromStringAndSize makes a copy of the buffer passed in.

@mdboom mdboom added this to the Next bugfix release (1.5.1) milestone Nov 2, 2015
@mdboom
Copy link
Member

mdboom commented Nov 2, 2015

👍 Thanks. (The values reported by the script in #5360 aren't very reliable and are certainly of the wrong scale, but this is a legit memory leak nonetheless).

mdboom added a commit that referenced this pull request Nov 2, 2015
@mdboom mdboom merged commit d6d64df into matplotlib:v1.5.x Nov 2, 2015
@QuLogic QuLogic deleted the cairo-memleak branch November 2, 2015 21:58
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.

3 participants