mirror of
				https://github.com/python/cpython.git
				synced 2025-11-04 07:31:38 +00:00 
			
		
		
		
	Release codecs variable earlier.
This commit is contained in:
		
							parent
							
								
									f4063ca8bc
								
							
						
					
					
						commit
						ba8e180f3b
					
				
					 1 changed files with 2 additions and 4 deletions
				
			
		| 
						 | 
				
			
			@ -230,16 +230,14 @@ PyObject *codec_getincrementalcodec(const char *encoding,
 | 
			
		|||
    if (codecs == NULL)
 | 
			
		||||
	return NULL;
 | 
			
		||||
    inccodec = PyObject_GetAttrString(codecs, attrname);
 | 
			
		||||
    if (inccodec == NULL) {
 | 
			
		||||
	Py_DECREF(codecs);
 | 
			
		||||
    Py_DECREF(codecs);
 | 
			
		||||
    if (inccodec == NULL)
 | 
			
		||||
	return NULL;
 | 
			
		||||
    }
 | 
			
		||||
    if (errors)
 | 
			
		||||
	ret = PyObject_CallFunction(inccodec, "s", errors);
 | 
			
		||||
    else
 | 
			
		||||
	ret = PyObject_CallFunction(inccodec, NULL);
 | 
			
		||||
    Py_DECREF(inccodec);
 | 
			
		||||
    Py_DECREF(codecs);
 | 
			
		||||
    return ret;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue