10000 _overlapped.ConnectPipe(): release the GIL · python/asyncio@54faf33 · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Nov 23, 2017. It is now read-only.

Commit 54faf33

Browse files
committed
_overlapped.ConnectPipe(): release the GIL
1 parent 29487bb commit 54faf33

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

overlapped.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1146,10 +1146,13 @@ ConnectPipe(OverlappedObject *self, PyObject *args)
11461146
if (Address == NULL)
11471147
return NULL;
11481148

1149+
Py_BEGIN_ALLOW_THREADS
11491150
PipeHandle = CreateFileW(Address,
11501151
GENERIC_READ | GENERIC_WRITE,
11511152
0, NULL, OPEN_EXISTING,
11521153
FILE_FLAG_OVERLAPPED, NULL);
1154+
Py_END_ALLOW_THREADS
1155+
11531156
PyMem_Free(Address);
11541157
if (PipeHandle == INVALID_HANDLE_VALUE)
11551158
return SetFromWindowsErr(0);

0 commit comments

Comments
 (0)
0