QPolygon memory leak

Phil Thompson phil at riverbankcomputing.com
Thu May 7 13:35:57 BST 2020


On 06/05/2020 12:33, Schoof, Tim wrote:
> Hi,
> 
> the following script leaks large amounts of memory:
> 
> from PyQt5.QtGui import QPolygonF
> from PyQt5.QtCore import QPointF
> 
> polygon = QPolygonF()
> polygon.append(QPointF(0, 0))
> 
> while True:
>     for point in polygon:
>         pass
> 
>     # point = polygon[0]  # this leaks as well
> 
> 
> This happens on Debian 9 and 10, Ubuntu 18.04.2, and in a Python 3.6.9
> venv with PyQt5-sip-12.7.2 and pyqt5-5.14.2 installed from wheels.
> 
> The leak also occurs with PyQt4.

Fixed in tonight's snapshot.

Thanks,
Phil


More information about the PyQt mailing list