From: Nikolay Sivov nsivov@codeweavers.com
Signed-off-by: Nikolay Sivov nsivov@codeweavers.com --- dlls/dxcore/dxcore.c | 10 ++++++++++ dlls/dxcore/tests/dxcore.c | 8 ++++---- 2 files changed, 14 insertions(+), 4 deletions(-)
diff --git a/dlls/dxcore/dxcore.c b/dlls/dxcore/dxcore.c index 6d475030258..e60740cc5eb 100644 --- a/dlls/dxcore/dxcore.c +++ b/dlls/dxcore/dxcore.c @@ -114,6 +114,16 @@ static HRESULT STDMETHODCALLTYPE dxcore_adapter_GetProperty(IDXCoreAdapter *ifac
switch (property) { + case InstanceLuid: + { + LUID *luid = buffer; + + if (buffer_size < sizeof(*luid)) + return E_INVALIDARG; + + *luid = adapter->identifier.adapter_luid; + break; + } case HardwareID: { struct DXCoreHardwareID *hardware_id = buffer; diff --git a/dlls/dxcore/tests/dxcore.c b/dlls/dxcore/tests/dxcore.c index 7677c82eb08..36953a757bf 100644 --- a/dlls/dxcore/tests/dxcore.c +++ b/dlls/dxcore/tests/dxcore.c @@ -178,9 +178,9 @@ static void test_GetProperty(void) hr = IDXCoreAdapter_GetProperty(adapter, InstanceLuid, 0, NULL); ok(hr == E_POINTER, "Got hr %#lx.\n", hr); hr = IDXCoreAdapter_GetProperty(adapter, InstanceLuid, 0, luid); - todo_wine ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr); + ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr); hr = IDXCoreAdapter_GetProperty(adapter, InstanceLuid, sizeof(luid[0]) - 1, luid); - todo_wine ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr); + ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IDXCoreAdapter_GetPropertySize(adapter, InstanceLuid, NULL); todo_wine ok(hr == E_POINTER, "Got hr %#lx.\n", hr); @@ -191,10 +191,10 @@ static void test_GetProperty(void) ok(size == sizeof(*luid), "Got size %Iu.\n", size);
hr = IDXCoreAdapter_GetProperty(adapter, InstanceLuid, sizeof(luid[0]), luid); - todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr); + ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IDXCoreAdapter_GetProperty(adapter, InstanceLuid, sizeof(luid[0]) + 1, luid); - todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr); + ok(hr == S_OK, "Got hr %#lx.\n", hr);
/* HardwareID */ hr = IDXCoreAdapter_GetProperty(adapter, HardwareID, 0, NULL);