[WINESYNC] setupapi: Fill the required size in SetupDiGetDeviceInterfaceDetail() also on success.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53387

wine commit id d15262e464ba3536567ad73f68d95e6b7f88f3aa by Zebediah Figura <zfigura@codeweavers.com>
This commit is contained in:
winesync 2023-09-14 22:06:42 +02:00 committed by Hermès Bélusca-Maïto
parent 060d6f2482
commit 5369aafbc0
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0
2 changed files with 3 additions and 3 deletions

View file

@ -1261,14 +1261,14 @@ static void test_device_iface_detail(void)
ret = SetupDiGetDeviceInterfaceDetailA(set, &iface, detail, expected_size, &size, NULL);
ok(ret, "Failed to get interface detail, error %#lx.\n", GetLastError());
ok(!strcasecmp(path, detail->DevicePath), "Got unexpected path %s.\n", detail->DevicePath);
todo_wine ok(size == expected_size, "Expected size %lu, got %lu.\n", expected_size, size);
ok(size == expected_size, "Expected size %lu, got %lu.\n", expected_size, size);
SetLastError(0xdeadbeef);
size = 0xdeadbeef;
ret = SetupDiGetDeviceInterfaceDetailA(set, &iface, detail, expected_size * 2, &size, NULL);
ok(ret, "Failed to get interface detail, error %#lx.\n", GetLastError());
ok(!strcasecmp(path, detail->DevicePath), "Got unexpected path %s.\n", detail->DevicePath);
todo_wine ok(size == expected_size, "Expected size %lu, got %lu.\n", expected_size, size);
ok(size == expected_size, "Expected size %lu, got %lu.\n", expected_size, size);
expected_size = FIELD_OFFSET(SP_DEVICE_INTERFACE_DETAIL_DATA_W, DevicePath[strlen(path) + 1]);

View file

@ -10,4 +10,4 @@ files:
dlls/setupapi/setupcab.c: dll/win32/setupapi/setupcab.c
dlls/setupapi/stringtable.c: dll/win32/setupapi/stringtable_wine.c
tags:
wine: 5711f03e8479936ac5e3bc71ba7987f6b7cb5586
wine: d15262e464ba3536567ad73f68d95e6b7f88f3aa