mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 21:51:50 +00:00 
			
		
		
		
	ssue #27942: Fix memory leak in codeobject.c
This commit is contained in:
		
							parent
							
								
									58c534dd6c
								
							
						
					
					
						commit
						d2fd3599ab
					
				
					 2 changed files with 4 additions and 0 deletions
				
			
		|  | @ -69,6 +69,7 @@ intern_string_constants(PyObject *tuple) | |||
|             intern_string_constants(v); | ||||
|         } | ||||
|         else if (PyFrozenSet_CheckExact(v)) { | ||||
|             PyObject *w = v; | ||||
|             PyObject *tmp = PySequence_Tuple(v); | ||||
|             if (tmp == NULL) { | ||||
|                 PyErr_Clear(); | ||||
|  | @ -81,6 +82,7 @@ intern_string_constants(PyObject *tuple) | |||
|                 } | ||||
|                 else { | ||||
|                     PyTuple_SET_ITEM(tuple, i, v); | ||||
|                     Py_DECREF(w); | ||||
|                     modified = 1; | ||||
|                 } | ||||
|             } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Yury Selivanov
						Yury Selivanov