@@ -2341,20 +2341,20 @@ void
2341
2341
PyEval_SetProfileAllThreads (Py_tracefunc func , PyObject * arg )
2342
2342
{
2343
2343
PyThreadState * this_tstate = _PyThreadState_GET ();
2344
- PyInterpreterState * interp = this_tstate -> interp ;
2344
+ PyInterpreterState * interp = this_tstate -> interp ;
2345
2345
2346
2346
_PyRuntimeState * runtime = & _PyRuntime ;
2347
- HEAD_LOCK ( runtime );
2347
+ INTERP_THREAD_LOCK ( interp );
2348
2348
PyThreadState * ts = PyInterpreterState_ThreadHead (interp );
2349
- HEAD_UNLOCK ( runtime );
2349
+ INTERP_THREAD_UNLOCK ( interp );
2350
2350
2351
2351
while (ts ) {
2352
2352
if (_PyEval_SetProfile (ts , func , arg ) < 0 ) {
2353
2353
PyErr_FormatUnraisable ("Exception ignored in PyEval_SetProfileAllThreads" );
2354
2354
}
2355
- HEAD_LOCK ( runtime );
2355
+ INTERP_THREAD_LOCK ( interp );
2356
2356
ts = PyThreadState_Next (ts );
2357
- HEAD_UNLOCK ( runtime );
2357
+ INTERP_THREAD_UNLOCK ( interp );
2358
2358
}
2359
2359
}
2360
2360
@@ -2372,20 +2372,20 @@ void
2372
2372
PyEval_SetTraceAllThreads (Py_tracefunc func , PyObject * arg )
2373
2373
{
2374
2374
PyThreadState * this_tstate = _PyThreadState_GET ();
2375
- PyInterpreterState * interp = this_tstate -> interp ;
2375
+ PyInterpreterState * interp = this_tstate -> interp ;
2376
2376
2377
2377
_PyRuntimeState * runtime = & _PyRuntime ;
2378
- HEAD_LOCK ( runtime );
2378
+ INTERP_THREAD_LOCK ( interp );
2379
2379
PyThreadState * ts = PyInterpreterState_ThreadHead (interp );
2380
- HEAD_UNLOCK ( runtime );
2380
+ INTERP_THREAD_UNLOCK ( interp );
2381
2381
2382
2382
while (ts ) {
2383
2383
if (_PyEval_SetTrace (ts , func , arg ) < 0 ) {
2384
2384
PyErr_FormatUnraisable ("Exception ignored in PyEval_SetTraceAllThreads" );
2385
2385
}
2386
- HEAD_LOCK ( runtime );
2386
+ INTERP_THREAD_LOCK ( interp );
2387
2387
ts = PyThreadState_Next (ts );
2388
- HEAD_UNLOCK ( runtime );
2388
+ INTERP_THREAD_UNLOCK ( interp );
2389
2389
}
2390
2390
}
2391
2391
0 commit comments