File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -8601,7 +8601,13 @@ static PyObject *
8601
8601
os_setns_impl (PyObject * module , int fd , int nstype )
8602
8602
/*[clinic end generated code: output=5dbd055bfb66ecd0 input=c097c9aa123c43ce]*/
8603
8603
{
8604
- if (setns (fd , nstype ) != 0 ) {
8604
+ int res ;
8605
+
8606
+ Py_BEGIN_ALLOW_THREADS
8607
+ res = setns (fd , nstype );
8608
+ Py_END_ALLOW_THREADS
8609
+
8610
+ if (res != 0 ) {
8605
8611
return posix_error ();
8606
8612
}
8607
8613
@@ -8622,7 +8628,13 @@ static PyObject *
8622
8628
os_unshare_impl (PyObject * module , int flags )
8623
8629
/*[clinic end generated code: output=1b3177906dd237ee input=f8d7bd2c69325537]*/
8624
8630
{
8625
- if (unshare (flags ) != 0 ) {
8631
+ int res ;
8632
+
8633
+ Py_BEGIN_ALLOW_THREADS
8634
+ res = unshare (flags );
8635
+ Py_END_ALLOW_THREADS
8636
+
8637
+ if (res != 0 ) {
8626
8638
return posix_error ();
8627
8639
}
8628
8640
You can’t perform that action at this time.
0 commit comments