Skip to content

Commit 7d4ac9d

Browse files
committed
Merge pull request #3274 from tacaswell/fix_fontprop_leak
BUG : fixes FontProperties memory leak
2 parents 32fe716 + a3b18a2 commit 7d4ac9d

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/matplotlib/font_manager.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -707,6 +707,12 @@ def __hash__(self):
707707
self.get_file())
708708
return hash(l)
709709

710+
def __eq__(self, other):
711+
return hash(self) == hash(other)
712+
713+
def __ne__(self, other):
714+
return hash(self) != hash(other)
715+
710716
def __str__(self):
711717
return self.get_fontconfig_pattern()
712718

0 commit comments

Comments
 (0)