mirror of
				https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
				synced 2025-11-03 09:01:50 -05:00 
			
		
		
		
	Plug some memory leaks and an invalid read
Note in protocol-dbus.c specifically, method_signatures needs to be freed before method_handlers, because otherwise h->method_name is freed while it is still in use as a key in the method_signatures hashmap.
This commit is contained in:
		
							parent
							
								
									a8f20e8d95
								
							
						
					
					
						commit
						b430407f47
					
				
					 5 changed files with 6 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -839,8 +839,8 @@ int pa_dbus_protocol_remove_interface(pa_dbus_protocol *p, const char* path, con
 | 
			
		|||
    pa_log_debug("Interface %s removed from object %s", iface_entry->name, obj_entry->path);
 | 
			
		||||
 | 
			
		||||
    pa_xfree(iface_entry->name);
 | 
			
		||||
    pa_hashmap_free(iface_entry->method_handlers, method_handler_free_cb, NULL);
 | 
			
		||||
    pa_hashmap_free(iface_entry->method_signatures, method_signature_free_cb, NULL);
 | 
			
		||||
    pa_hashmap_free(iface_entry->method_handlers, method_handler_free_cb, NULL);
 | 
			
		||||
    pa_hashmap_free(iface_entry->property_handlers, property_handler_free_cb, NULL);
 | 
			
		||||
 | 
			
		||||
    for (i = 0; i < iface_entry->n_signals; ++i) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue