mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	examples: fix some leaks
This commit is contained in:
		
							parent
							
								
									27f811d726
								
							
						
					
					
						commit
						8f7a19f2e3
					
				
					 3 changed files with 3 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -408,7 +408,7 @@ static int impl_node_process_input(void *data)
 | 
			
		|||
	SDL_RenderPresent(d->renderer);
 | 
			
		||||
 | 
			
		||||
	if (map)
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize);
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize + buf->datas[0].mapoffset);
 | 
			
		||||
 | 
			
		||||
	handle_events(d);
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -389,7 +389,7 @@ static int impl_node_process_input(void *data)
 | 
			
		|||
	SDL_RenderPresent(d->renderer);
 | 
			
		||||
 | 
			
		||||
	if (map)
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize);
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize + buf->datas[0].mapoffset);
 | 
			
		||||
 | 
			
		||||
	handle_events(d);
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -142,7 +142,7 @@ on_stream_new_buffer(void *_data, uint32_t id)
 | 
			
		|||
	SDL_RenderPresent(data->renderer);
 | 
			
		||||
 | 
			
		||||
	if (map)
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize);
 | 
			
		||||
		munmap(map, buf->datas[0].maxsize + buf->datas[0].mapoffset);
 | 
			
		||||
 | 
			
		||||
	pw_stream_recycle_buffer(stream, id);
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue