Repository navigation
Commit 6ae261e
committed
shield connection close in terminate
If terminate is called from an asyncio.CancelledError exception handler,
under an anyio task group, await will bail with asyncio.CancelledError
right away, leading to a connection leak.
Shielding the close() call allows the connection to be properly closed
in those cases.1 parent ef23611 commit 6ae261e
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
915 | 915 | | |
916 | 916 | | |
917 | 917 | | |
918 | | - | |
| 918 | + | |
919 | 919 | | |
920 | 920 | | |
921 | 921 | | |
| |||
0 commit comments