mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	pulse-server: limit packets to fragsize
When sending captured data to a client, pulseaudio limits the size of the block to the fragsize. Let's do the same just in case a client can't deal with more data. See #615
This commit is contained in:
		
							parent
							
								
									c25bdce645
								
							
						
					
					
						commit
						4f28edd4f7
					
				
					 1 changed files with 5 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -1513,6 +1513,11 @@ do_process_done(struct spa_loop *loop,
 | 
			
		|||
				avail = stream->attr.fragsize;
 | 
			
		||||
				index = stream->write_index - avail;
 | 
			
		||||
			}
 | 
			
		||||
			else if (avail > (int32_t)stream->attr.fragsize) {
 | 
			
		||||
				pw_log_debug(NAME" %p: [%s] limit avail:%d > frag:%u",
 | 
			
		||||
					stream, client->name, avail, stream->attr.fragsize);
 | 
			
		||||
				avail = stream->attr.fragsize;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			msg = message_alloc(impl, stream->channel, avail);
 | 
			
		||||
			if (msg == NULL)
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue