mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 23:21:29 +00:00 
			
		
		
		
	gh-131316: fix invalid DECREF in _md5.md5.copy() (#135291)
				
					
				
			This amends commit 261633bd3f.
			
			
This commit is contained in:
		
							parent
							
								
									8441b263af
								
							
						
					
					
						commit
						c19e36cc4e
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -120,7 +120,7 @@ MD5Type_copy_impl(MD5object *self, PyTypeObject *cls)
 | 
				
			||||||
    newobj->hash_state = Hacl_Hash_MD5_copy(self->hash_state);
 | 
					    newobj->hash_state = Hacl_Hash_MD5_copy(self->hash_state);
 | 
				
			||||||
    LEAVE_HASHLIB(self);
 | 
					    LEAVE_HASHLIB(self);
 | 
				
			||||||
    if (newobj->hash_state == NULL) {
 | 
					    if (newobj->hash_state == NULL) {
 | 
				
			||||||
        Py_DECREF(self);
 | 
					        Py_DECREF(newobj);
 | 
				
			||||||
        return PyErr_NoMemory();
 | 
					        return PyErr_NoMemory();
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    return (PyObject *)newobj;
 | 
					    return (PyObject *)newobj;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue