Skip to content

Memory leak in memoryview iterator  #92804

Description

@kumaraditya303

memoryview iterator leaks memory at exit as it is not finalized.

Reproducer:

print(type(iter(memoryview(b'abc'))).mro())

Memory leak:

@kumaraditya303 ➜ /workspaces/cpython (main ✗) $ ./python -X showrefcount main.py 
[<class 'memory_iterator'>, <class 'object'>]
[123 refs, 47 blocks]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

3.11only security fixes3.12only security fixestype-bugAn unexpected behavior, bug, or error

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions