mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	impl-port: warn and not crash when spa-node has no properties
When a spa-node tells us it has updated properties but then gives us a NULL pointer, emit a warning instead of crashing.
This commit is contained in:
		
							parent
							
								
									293932d4ec
								
							
						
					
					
						commit
						cd77ceebbc
					
				
					 1 changed files with 5 additions and 1 deletions
				
			
		| 
						 | 
					@ -329,7 +329,11 @@ static void update_info(struct pw_impl_port *port, const struct spa_port_info *i
 | 
				
			||||||
		port->spa_flags = info->flags;
 | 
							port->spa_flags = info->flags;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (info->change_mask & SPA_PORT_CHANGE_MASK_PROPS) {
 | 
						if (info->change_mask & SPA_PORT_CHANGE_MASK_PROPS) {
 | 
				
			||||||
 | 
							if (info->props) {
 | 
				
			||||||
			update_properties(port, info->props);
 | 
								update_properties(port, info->props);
 | 
				
			||||||
 | 
							} else {
 | 
				
			||||||
 | 
								pw_log_warn(NAME" %p: port PROPS update but no properties");
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (info->change_mask & SPA_PORT_CHANGE_MASK_PARAMS) {
 | 
						if (info->change_mask & SPA_PORT_CHANGE_MASK_PARAMS) {
 | 
				
			||||||
		uint32_t i;
 | 
							uint32_t i;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue