From: Rémi Bernon rbernon@codeweavers.com
--- dlls/dinput/tests/driver_bus.c | 7 ++++--- dlls/dinput/tests/driver_hid.h | 2 +- dlls/dinput/tests/hid.c | 8 ++++---- 3 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/dlls/dinput/tests/driver_bus.c b/dlls/dinput/tests/driver_bus.c index c0d181c58a5..7674d8538cd 100644 --- a/dlls/dinput/tests/driver_bus.c +++ b/dlls/dinput/tests/driver_bus.c @@ -131,7 +131,7 @@ static void expect_queue_reset( struct expect_queue *queue, void *buffer, unsign while (tmp != missing_end) { winetest_push_context( "%s expect[%Id]", context, tmp - missing ); - if (tmp->broken) + if (tmp->broken_id) { todo_wine_if( tmp->todo ) win_skip( "broken (code %#lx id %u len %u)\n", tmp->code, tmp->report_id, tmp->report_len ); @@ -251,8 +251,9 @@ static void expect_queue_next( struct expect_queue *queue, ULONG code, HID_XFER_ tmp = queue->pos; while (tmp < queue->end) { + BOOL is_missing = tmp->broken_id == (BYTE)-1; if (winetest_platform_is_wine && !tmp->todo) break; - if (!winetest_platform_is_wine && !tmp->broken && !tmp->wine_only) break; + if (!winetest_platform_is_wine && !is_missing && !tmp->wine_only) break; if (tmp->code == code && tmp->report_id == id && tmp->report_len == len && (!compare_buf || RtlCompareMemory( tmp->report_buf, buf, len ) == len)) break; @@ -303,7 +304,7 @@ static void expect_queue_next( struct expect_queue *queue, ULONG code, HID_XFER_ while (tmp != missing_end) { winetest_push_context( "%s expect[%Id]", context, tmp - missing ); - if (tmp->broken) + if (tmp->broken_id) { todo_wine_if( tmp->todo ) win_skip( "broken (code %#lx id %u len %u)\n", tmp->code, tmp->report_id, tmp->report_len ); diff --git a/dlls/dinput/tests/driver_hid.h b/dlls/dinput/tests/driver_hid.h index ee5d26cdbf7..a824e004dfa 100644 --- a/dlls/dinput/tests/driver_hid.h +++ b/dlls/dinput/tests/driver_hid.h @@ -56,7 +56,7 @@ struct hid_expect DWORD ret_length; DWORD ret_status; BYTE todo; /* missing on wine */ - BYTE broken; /* missing on some win versions */ + BYTE broken_id; /* different or missing (-1) report on some win versions */ BYTE wine_only; BYTE report_id; BYTE report_len; diff --git a/dlls/dinput/tests/hid.c b/dlls/dinput/tests/hid.c index 0a28fda6f99..1c18acd6f35 100644 --- a/dlls/dinput/tests/hid.c +++ b/dlls/dinput/tests/hid.c @@ -1048,7 +1048,7 @@ static void test_hidp_get_input( HANDLE file, int report_id, ULONG report_len, P struct hid_expect broken_expect = { .code = IOCTL_HID_GET_INPUT_REPORT, - .broken = TRUE, + .broken_id = -1, .report_len = report_len - 1, .report_buf = { @@ -1142,7 +1142,7 @@ static void test_hidp_get_feature( HANDLE file, int report_id, ULONG report_len, struct hid_expect broken_expect = { .code = IOCTL_HID_GET_FEATURE, - .broken = TRUE, + .broken_id = -1, .report_len = report_len - 1, .report_buf = { @@ -1240,7 +1240,7 @@ static void test_hidp_set_feature( HANDLE file, int report_id, ULONG report_len, struct hid_expect broken_expect = { .code = IOCTL_HID_SET_FEATURE, - .broken = TRUE, + .broken_id = -1, .report_len = report_len - 1, .report_buf = { @@ -1341,7 +1341,7 @@ static void test_hidp_set_output( HANDLE file, int report_id, ULONG report_len, struct hid_expect broken_expect = { .code = IOCTL_HID_SET_OUTPUT_REPORT, - .broken = TRUE, + .broken_id = -1, .report_len = report_len - 1, .report_buf = {0x5a,0x5a}, .ret_length = 3,