Commit 63b52e8e675c559aeadae531f8fab813af73d816

Sam Lantinga 2020-11-21T18:34:32

Remove SDL dependency in Windows code

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/src/hidapi/windows/hid.c b/src/hidapi/windows/hid.c
index 1d17714..d60cb6f 100644
--- a/src/hidapi/windows/hid.c
+++ b/src/hidapi/windows/hid.c
@@ -326,7 +326,7 @@ int hid_blacklist(unsigned short vendor_id, unsigned short product_id)
         { 0x0738, 0x2217 }   /* SPEEDLINK COMPETITION PRO */
     };
 
-    for (i = 0; i < SDL_arraysize(known_bad); i++) {
+    for (i = 0; i < (sizeof(known_bad)/sizeof(known_bad[0])); i++) {
         if ((vendor_id == known_bad[i].vid) && (product_id == known_bad[i].pid)) {
             return 1;
         }