mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-25 14:45:12 +00:00
fix: avoid changing class outside of GIL
This commit is contained in:
parent
dff9b3b432
commit
732bf88d19
@ -52,9 +52,11 @@ private:
|
|||||||
|
|
||||||
pywrite(line);
|
pywrite(line);
|
||||||
pyflush();
|
pyflush();
|
||||||
|
|
||||||
|
// Placed inside gil_scoped_aquire as a mutex to avoid a race
|
||||||
|
setp(pbase(), epptr());
|
||||||
}
|
}
|
||||||
|
|
||||||
setp(pbase(), epptr());
|
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user