From 5d904d27491aab489d54746bc6650b27c5927c39 Mon Sep 17 00:00:00 2001 From: Axel Davy Date: Tue, 4 Jun 2019 00:37:28 +0200 Subject: [PATCH] st/nine: Improve return error code in CheckDeviceFormat This seems suspicious, but is better than what we currently do. Signed-off-by: Axel Davy Part-of: --- src/gallium/frontends/nine/adapter9.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gallium/frontends/nine/adapter9.c b/src/gallium/frontends/nine/adapter9.c index 200e5389949..356cbb6e6dc 100644 --- a/src/gallium/frontends/nine/adapter9.c +++ b/src/gallium/frontends/nine/adapter9.c @@ -297,7 +297,9 @@ NineAdapter9_CheckDeviceFormat( struct NineAdapter9 *This, DBG("Usage=%x RType=%u CheckFormat=%s\n", Usage, RType, d3dformat_to_string(CheckFormat)); - user_assert(display_format(AdapterFormat, FALSE), D3DERR_INVALIDCALL); + /* Wine tests, but suspicious. Needs more tests. */ + user_assert(adapter_format(AdapterFormat), D3DERR_INVALIDCALL); + user_assert(display_format(AdapterFormat, FALSE), D3DERR_NOTAVAILABLE); hr = NineAdapter9_GetScreen(This, DeviceType, &screen); if (FAILED(hr)) -- 2.30.2