mirror of
				https://gitlab.freedesktop.org/wlroots/wlroots.git
				synced 2025-11-03 09:01:40 -05:00 
			
		
		
		
	linux-dmabuf-v1: fix implicit check
The implicit check to filter out LINEAR for dmabuf checked for INVALID
twice instead of checking for INVALID & LINEAR. Fix this.
Fixes: d37eb5c2ea ("linux-dmabuf-v1: filter out LINEAR if implicit")
Reported-by: Dawid Czeluśniak <czelusniakdawid@gmail.com>
			
			
This commit is contained in:
		
							parent
							
								
									fbaefd90fc
								
							
						
					
					
						commit
						6bfb930aa7
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -437,7 +437,7 @@ static void linux_dmabuf_send_modifiers(struct wl_resource *resource,
 | 
				
			||||||
	// In case only INVALID and LINEAR are advertised, send INVALID only due to XWayland:
 | 
						// In case only INVALID and LINEAR are advertised, send INVALID only due to XWayland:
 | 
				
			||||||
	// https://gitlab.freedesktop.org/xorg/xserver/-/issues/1166
 | 
						// https://gitlab.freedesktop.org/xorg/xserver/-/issues/1166
 | 
				
			||||||
	if (fmt->len == 2 && wlr_drm_format_has(fmt, DRM_FORMAT_MOD_INVALID)
 | 
						if (fmt->len == 2 && wlr_drm_format_has(fmt, DRM_FORMAT_MOD_INVALID)
 | 
				
			||||||
			&& wlr_drm_format_has(fmt, DRM_FORMAT_MOD_INVALID)) {
 | 
								&& wlr_drm_format_has(fmt, DRM_FORMAT_MOD_LINEAR)) {
 | 
				
			||||||
		uint64_t mod = DRM_FORMAT_MOD_INVALID;
 | 
							uint64_t mod = DRM_FORMAT_MOD_INVALID;
 | 
				
			||||||
		zwp_linux_dmabuf_v1_send_modifier(resource, fmt->format,
 | 
							zwp_linux_dmabuf_v1_send_modifier(resource, fmt->format,
 | 
				
			||||||
			mod >> 32, mod & 0xFFFFFFFF);
 | 
								mod >> 32, mod & 0xFFFFFFFF);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue