mirror of
				https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
				synced 2025-11-03 09:01:50 -05:00 
			
		
		
		
	optimize set_state_in_io_thread() callbacks
Source and sink are passed in arguments to set_state_in_io_thread() callbacks. There is optimal to access them directly.
This commit is contained in:
		
							parent
							
								
									de705a0eea
								
							
						
					
					
						commit
						556cdfa190
					
				
					 16 changed files with 41 additions and 41 deletions
				
			
		| 
						 | 
				
			
			@ -296,7 +296,7 @@ static int sink_set_state_in_io_thread_cb(pa_sink *s, pa_sink_state_t new_state,
 | 
			
		|||
 | 
			
		||||
    /* When set to running or idle for the first time, request a rewind
 | 
			
		||||
     * of the master sink to make sure we are heard immediately */
 | 
			
		||||
    if ((new_state == PA_SINK_IDLE || new_state == PA_SINK_RUNNING) && u->sink->thread_info.state == PA_SINK_INIT) {
 | 
			
		||||
    if (PA_SINK_IS_OPENED(new_state) && s->thread_info.state == PA_SINK_INIT) {
 | 
			
		||||
        pa_log_debug("Requesting rewind due to state change.");
 | 
			
		||||
        pa_sink_input_request_rewind(u->sink_input, 0, false, true, true);
 | 
			
		||||
    }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue