mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	pw-dump: output Spa:String:JSON values as literal
Don't escape the Spa:String:JSON types in the metadata as it is supposed to be valid JSON that can be output directly. We might want to reparse and reformat it later to be sure.
This commit is contained in:
		
							parent
							
								
									d8e3f9b801
								
							
						
					
					
						commit
						bded2a02a0
					
				
					 1 changed files with 4 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -1068,7 +1068,10 @@ static void metadata_dump(struct object *o)
 | 
			
		|||
		put_int(d, "subject", e->subject);
 | 
			
		||||
		put_value(d, "key", e->key);
 | 
			
		||||
		put_value(d, "type", e->type);
 | 
			
		||||
		put_value(d, "value", e->value);
 | 
			
		||||
		if (e->type != NULL && strcmp(e->type, "Spa:String:JSON") == 0)
 | 
			
		||||
			put_literal(d, "value", e->value);
 | 
			
		||||
		else
 | 
			
		||||
			put_value(d, "value", e->value);
 | 
			
		||||
		put_end(d, "}", STATE_SIMPLE);
 | 
			
		||||
		e->changed = 0;
 | 
			
		||||
	}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue