[PATCH 1/5] dxgi: Simplify dxgi_adapter_GetDesc().
25 Sep
2018
25 Sep
'18
8:33 a.m.
Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> --- dlls/dxgi/adapter.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dlls/dxgi/adapter.c b/dlls/dxgi/adapter.c index b7d7a0a65aae..1f81d7717e1b 100644 --- a/dlls/dxgi/adapter.c +++ b/dlls/dxgi/adapter.c @@ -200,9 +200,8 @@ static HRESULT STDMETHODCALLTYPE dxgi_adapter_GetDesc(IWineDXGIAdapter *iface, D if (!desc) return E_INVALIDARG; - if (FAILED(hr = dxgi_adapter_GetDesc1(iface, &desc1))) - return hr; - memcpy(desc, &desc1, sizeof(*desc)); + if (SUCCEEDED(hr = dxgi_adapter_GetDesc1(iface, &desc1))) + memcpy(desc, &desc1, sizeof(*desc)); return hr; } -- 2.16.4
2639
Age (days ago)
2639
Last active (days ago)
1 comments
2 participants
participants (2)
-
Henri Verbeet -
Józef Kucia