ndis.sys/tests: Test passing a bogus OID to IOCTL_NDIS_QUERY_GLOBAL_STATS.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2021-09-22 23:00:37 -05:00 committed by Alexandre Julliard
parent cac8c971a7
commit ef18fb9a3b
1 changed files with 9 additions and 0 deletions

View File

@ -58,6 +58,15 @@ static void test_device(const WCHAR *service_name, const MIB_IF_ROW2 *row)
return; return;
} }
oid = 0xdeadbeef;
iosb.Status = 0xdeadbeef;
iosb.Information = 0xdeadbeef;
status = NtDeviceIoControlFile( netdev, NULL, NULL, NULL, &iosb,
IOCTL_NDIS_QUERY_GLOBAL_STATS, &oid, sizeof(oid), &medium, sizeof(medium) );
todo_wine ok(status == STATUS_INVALID_PARAMETER, "got status %#x\n", status);
ok(iosb.Status == 0xdeadbeef, "got %#x\n", iosb.Status);
ok(iosb.Information == 0xdeadbeef, "got size %#Ix\n", iosb.Information);
oid = OID_GEN_MEDIA_SUPPORTED; oid = OID_GEN_MEDIA_SUPPORTED;
ret = DeviceIoControl( netdev, IOCTL_NDIS_QUERY_GLOBAL_STATS, ret = DeviceIoControl( netdev, IOCTL_NDIS_QUERY_GLOBAL_STATS,
&oid, sizeof(oid), &medium, sizeof(medium), &size, NULL ); &oid, sizeof(oid), &medium, sizeof(medium), &size, NULL );