summaryrefslogtreecommitdiffstats
path: root/Python/ceval.c
diff options
context:
space:
mode:
authorHood Chatham <roberthoodchatham@gmail.com>2022-04-03 20:58:52 (GMT)
committerGitHub <noreply@github.com>2022-04-03 20:58:52 (GMT)
commit087d0fa5b97796560c0d8ceab4f0360fd54baf4f (patch)
tree975274b43e0cc50d11f70ba0c6a8fd344d74d632 /Python/ceval.c
parentbdc497496548e30fa208a8d98c30bf6d1833ac4c (diff)
downloadcpython-087d0fa5b97796560c0d8ceab4f0360fd54baf4f.zip
cpython-087d0fa5b97796560c0d8ceab4f0360fd54baf4f.tar.gz
cpython-087d0fa5b97796560c0d8ceab4f0360fd54baf4f.tar.bz2
bpo-47176: Interrupt handling for wasm32-emscripten builds without pthreads (GH-32209)
Co-authored-by: Christian Heimes <christian@python.org> Co-authored-by: Brett Cannon <brett@python.org>
Diffstat (limited to 'Python/ceval.c')
-rw-r--r--Python/ceval.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index 43080f8..68d2920 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -21,6 +21,7 @@
#include "pycore_pystate.h" // _PyInterpreterState_GET()
#include "pycore_sysmodule.h" // _PySys_Audit()
#include "pycore_tuple.h" // _PyTuple_ITEMS()
+#include "pycore_emscripten_signal.h" // _Py_CHECK_EMSCRIPTEN_SIGNALS
#include "code.h"
#include "pycore_dict.h"
@@ -1292,6 +1293,7 @@ eval_frame_handle_pending(PyThreadState *tstate)
}
#define CHECK_EVAL_BREAKER() \
+ _Py_CHECK_EMSCRIPTEN_SIGNALS_PERIODICALLY(); \
if (_Py_atomic_load_relaxed(eval_breaker)) { \
goto handle_eval_breaker; \
}