mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-30 19:22:31 +00:00 
			
		
		
		
	Merge pull request #5113 from YosysHQ/krys/ast_asan
simplify.cc: Fix mem leak
This commit is contained in:
		
						commit
						05157b164e
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		|  | @ -1932,6 +1932,8 @@ bool AstNode::simplify(bool const_fold, int stage, int width_hint, bool sign_hin | |||
| 			// Prepare replacement node.
 | ||||
| 			newNode = template_node->clone(); | ||||
| 			newNode->str = str; | ||||
| 			if (newNode->attributes.count(ID::wiretype)) | ||||
| 				delete newNode->attributes[ID::wiretype]; | ||||
| 			newNode->set_attribute(ID::wiretype, mkconst_str(resolved_type_node->str)); | ||||
| 			newNode->is_input = is_input; | ||||
| 			newNode->is_output = is_output; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue