mirror of
				https://gitlab.freedesktop.org/wayland/wayland.git
				synced 2025-11-03 09:01:42 -05:00 
			
		
		
		
	wayland-shm: Check visual for being NULL
This commit is contained in:
		
							parent
							
								
									eff7fc0d99
								
							
						
					
					
						commit
						b06e891e4c
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -119,7 +119,7 @@ shm_create_buffer(struct wl_client *client, struct wl_shm *shm,
 | 
				
			||||||
	struct wl_shm_buffer *buffer;
 | 
						struct wl_shm_buffer *buffer;
 | 
				
			||||||
	void *data;
 | 
						void *data;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (visual->object.interface != &wl_visual_interface) {
 | 
						if (!visual || visual->object.interface != &wl_visual_interface) {
 | 
				
			||||||
		wl_client_post_error(client, &shm->object,
 | 
							wl_client_post_error(client, &shm->object,
 | 
				
			||||||
				     WL_SHM_ERROR_INVALID_VISUAL,
 | 
									     WL_SHM_ERROR_INVALID_VISUAL,
 | 
				
			||||||
				     "invalid visual");
 | 
									     "invalid visual");
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue