Skip to content

possible memory leaks and issues during finalizer #173

@carandraug

Description

@carandraug

There has been some hints that the current implementation may have memory leaks and that FT_Done_* is not always called as expected. Related issues include #44 and #169, and the discussion in the pull request #171.

  1. The core of issue on exit, freetype/__init__.py", line 1233, in __del__ TypeError: 'NoneType' object is not callable #169 and another described in the comments of access violation writing error in Face.__del__() #44 is what happens during interpreter shutdown, namely that we can't rely on the FT_Done_* functions to exist at that step. This was fixed for Face in pull request freetype.Face.__del__: check first if FT_Face_Done has been set to None (#169) #171. However, I think we're making the same mistake in Glyph.__del__ and Stroker.__del__. I can prepare a PR for this.

  2. The issue access violation writing error in Face.__del__() #44 and some of the comments in issue on exit, freetype/__init__.py", line 1233, in __del__ TypeError: 'NoneType' object is not callable #169 and PR freetype.Face.__del__: check first if FT_Face_Done has been set to None (#169) #171 seem to hint to some memory leaks but it's not clear to me how to reproduce it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions