Skip to content
This repository was archived by the owner on Sep 13, 2024. It is now read-only.

Commit 51c3422

Browse files
committed
Merge pull request #52 from chrysn-pull-requests/actually-close-socket
transports: Close socket when closing the transport
2 parents c534f08 + f2ac517 commit 51c3422

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Bugfixes
1111

1212
* Corrected the import of ``InvalidStateError`` to fix an error seen on Python 3.8+. (`#56 <https://github.com/beeware/gbulb/issues/56>`__)
1313

14+
* Reverted the fix from #47; that change led to file descriptor leaks. (`#52 <https://github.com/beeware/gbulb/issues/52>`_)
15+
1416

1517
0.6.2 (2021-10-24)
1618
------------------

src/gbulb/transports.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def _force_close_async(self, exc):
7575
self._protocol.connection_lost(exc)
7676
finally:
7777
if self._sock is not None:
78-
self._sock.detach()
78+
self._sock.close()
7979
self._sock = None
8080
if self._server is not None:
8181
self._server._detach()

0 commit comments

Comments
 (0)