Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

_SSLProtocolTransport keeps reference to protocol after close #98539

Closed
Assignees
kumaraditya303
Labels
3.11only security fixes3.12only security fixestopic-asynciotype-bugAn unexpected behavior, bug, or error
@kumaraditya303

Description

@kumaraditya303

_SSLProtocolTransport keeps reference to protocol after close. It leads to reference cyeles between the transport and the protocol and is bad for gc. Clearing this is better as it frees up the memory immediately without waiting for the gc. This causes memory leaks in some cases as if an exception occurs the deallocation is delayed even further as tracebacks keeps ref to frame and frame keeps locals alive.

defclose(self):
"""Close the transport.
Buffered data will be flushed asynchronously. No more data
will be received. After all buffered data is flushed, the
protocol's connection_lost() method will (eventually) called
with None as its argument.
"""
self._closed=True
self._ssl_protocol._start_shutdown()

Linked PRs

Metadata

Metadata

Labels

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

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions


    [8]ページ先頭

    ©2009-2025 Movatter.jp