mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 19:34:08 +00:00 
			
		
		
		
	replace thread state objects' ticker and checkinterval fields with two
globals, _Py_Ticker and _Py_CheckInterval.  This also implements Jeremy's
shortcut in Py_AddPendingCall that zeroes out _Py_Ticker.  This allows the
test in the main loop to only test a single value.
The gory details are at
    http://python.org/sf/602191
			
			
This commit is contained in:
		
							parent
							
								
									d229b3ae04
								
							
						
					
					
						commit
						d581d7792b
					
				
					 5 changed files with 15 additions and 10 deletions
				
			
		| 
						 | 
				
			
			@ -352,8 +352,7 @@ and return.  See the profiler chapter in the library manual."
 | 
			
		|||
static PyObject *
 | 
			
		||||
sys_setcheckinterval(PyObject *self, PyObject *args)
 | 
			
		||||
{
 | 
			
		||||
	PyThreadState *tstate = PyThreadState_Get();
 | 
			
		||||
	if (!PyArg_ParseTuple(args, "i:setcheckinterval", &tstate->interp->checkinterval))
 | 
			
		||||
	if (!PyArg_ParseTuple(args, "i:setcheckinterval", &_Py_CheckInterval))
 | 
			
		||||
		return NULL;
 | 
			
		||||
	Py_INCREF(Py_None);
 | 
			
		||||
	return Py_None;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue