Skip to content

Commit 8b90b1d

Browse files
committed
error_already_set: acquire GIL one line earlier (fixes #1779)
1 parent 502ffe5 commit 8b90b1d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/pybind11/pybind11.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1998,8 +1998,8 @@ class gil_scoped_release { };
19981998

19991999
error_already_set::~error_already_set() {
20002000
if (m_type) {
2001-
error_scope scope;
20022001
gil_scoped_acquire gil;
2002+
error_scope scope;
20032003
m_type.release().dec_ref();
20042004
m_value.release().dec_ref();
20052005
m_trace.release().dec_ref();

0 commit comments

Comments
 (0)