mirror of
				https://gitlab.freedesktop.org/wlroots/wlroots.git
				synced 2025-11-03 09:01:40 -05:00 
			
		
		
		
	backend/wayland: fix segfault in wlr_wl_output_destroy
This commit is contained in:
		
							parent
							
								
									01bcc2ab01
								
							
						
					
					
						commit
						6fa0a91ee2
					
				
					 1 changed files with 3 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -18,10 +18,12 @@ int os_create_anonymous_file(off_t size);
 | 
			
		|||
static struct wl_callback_listener frame_listener;
 | 
			
		||||
 | 
			
		||||
static void surface_frame_callback(void *data, struct wl_callback *cb, uint32_t time) {
 | 
			
		||||
	struct wlr_output *wlr_output = data;
 | 
			
		||||
	struct wlr_wl_backend_output *output = data;
 | 
			
		||||
	struct wlr_output *wlr_output = (struct wlr_output *)output;
 | 
			
		||||
	assert(wlr_output);
 | 
			
		||||
	wl_signal_emit(&wlr_output->events.frame, wlr_output);
 | 
			
		||||
	wl_callback_destroy(cb);
 | 
			
		||||
	output->frame_callback = NULL;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
static struct wl_callback_listener frame_listener = {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue