mirror of
				https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
				synced 2025-11-03 09:01:50 -05:00 
			
		
		
		
	passthrough: Fix setting volume to unamplified again
Thanks to Tanu for pointing out the (possibly pathological?) case that base_volume might be >0dB.
This commit is contained in:
		
							parent
							
								
									a13a402ed3
								
							
						
					
					
						commit
						ed4a4480dc
					
				
					 2 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -1406,7 +1406,7 @@ void pa_sink_enter_passthrough(pa_sink *s) {
 | 
			
		|||
    s->saved_volume = *pa_sink_get_volume(s, TRUE);
 | 
			
		||||
    s->saved_save_volume = s->save_volume;
 | 
			
		||||
 | 
			
		||||
    pa_cvolume_set(&volume, s->sample_spec.channels, s->base_volume);
 | 
			
		||||
    pa_cvolume_set(&volume, s->sample_spec.channels, PA_MIN(s->base_volume, PA_VOLUME_NORM));
 | 
			
		||||
    pa_sink_set_volume(s, &volume, TRUE, FALSE);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue