mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-10-29 05:40:27 -04:00 
			
		
		
		
	pulse-server: module: only cancel unload work if added
Only try to cancel the unload work in the work queue if one has actually been added.
This commit is contained in:
		
							parent
							
								
									f4fd884b15
								
							
						
					
					
						commit
						186d0a783e
					
				
					 1 changed files with 3 additions and 1 deletions
				
			
		|  | @ -103,8 +103,10 @@ void module_free(struct module *module) | ||||||
| 	if (module->index != SPA_ID_INVALID) | 	if (module->index != SPA_ID_INVALID) | ||||||
| 		pw_map_remove(&impl->modules, module->index & MODULE_INDEX_MASK); | 		pw_map_remove(&impl->modules, module->index & MODULE_INDEX_MASK); | ||||||
| 
 | 
 | ||||||
|  | 	if (module->unloading) | ||||||
|  | 		pw_work_queue_cancel(impl->work_queue, module, SPA_ID_INVALID); | ||||||
|  | 
 | ||||||
| 	spa_hook_list_clean(&module->listener_list); | 	spa_hook_list_clean(&module->listener_list); | ||||||
| 	pw_work_queue_cancel(impl->work_queue, module, SPA_ID_INVALID); |  | ||||||
| 	pw_properties_free(module->props); | 	pw_properties_free(module->props); | ||||||
| 
 | 
 | ||||||
| 	free((char*)module->name); | 	free((char*)module->name); | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Barnabás Pőcze
						Barnabás Pőcze