From: Alistair Leslie-Hughes Subject: [PATCH v2 1/2] d3dx9_36: Handle NULL palette Message-Id: Date: Sun, 22 Mar 2020 04:05:36 +0000 D3DFMT_P8 don't have a palette and cause a if they have to_rgba function. Signed-off-by: Alistair Leslie-Hughes --- dlls/d3dx9_36/surface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/d3dx9_36/surface.c b/dlls/d3dx9_36/surface.c index 42e7bf16f1..e2b398345c 100644 --- a/dlls/d3dx9_36/surface.c +++ b/dlls/d3dx9_36/surface.c @@ -1796,7 +1796,7 @@ void point_filter_argb_pixels(const BYTE *src, UINT src_row_pitch, UINT src_slic struct vec4 color, tmp; format_to_vec4(src_format, src_ptr, &color); - if (src_format->to_rgba) + if (src_format->to_rgba && palette) src_format->to_rgba(&color, &tmp, palette); else tmp = color; -- 2.25.1