examples/hotplugtest.c:76:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
vendor_id = (argc > 1) ? strtol (argv[1], NULL, 0) : 0x045a;
~ ^~~~~~~~~~~~~~~~~~~~~~~~~
examples/hotplugtest.c:77:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
product_id = (argc > 2) ? strtol (argv[2], NULL, 0) : 0x5005;
~ ^~~~~~~~~~~~~~~~~~~~~~~~~
examples/hotplugtest.c:78:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
class_id = (argc > 3) ? strtol (argv[3], NULL, 0) : LIBUSB_HOTPLUG_MATCH_ANY;
~ ^~~~~~~~~~~~~~~~~~~~~~~~~
int product_id, vendor_id, class_id;
int rc;
- vendor_id = (argc > 1) ? strtol (argv[1], NULL, 0) : 0x045a;
- product_id = (argc > 2) ? strtol (argv[2], NULL, 0) : 0x5005;
- class_id = (argc > 3) ? strtol (argv[3], NULL, 0) : LIBUSB_HOTPLUG_MATCH_ANY;
+ vendor_id = (argc > 1) ? (int)strtol (argv[1], NULL, 0) : 0x045a;
+ product_id = (argc > 2) ? (int)strtol (argv[2], NULL, 0) : 0x5005;
+ class_id = (argc > 3) ? (int)strtol (argv[3], NULL, 0) : LIBUSB_HOTPLUG_MATCH_ANY;
rc = libusb_init (NULL);
if (rc < 0)
-#define LIBUSB_NANO 11094
+#define LIBUSB_NANO 11095