Hi all, good work on this project..

I was wondering if anyone knows why the hid_compare_usb_device function does
a bitwise AND of the vendor and product IDs? For example, the product ID is
matched with the following code..

if (dev->descriptor.idVendor > 0 &&  (dev->descriptor.idVendor &
match->vendor_id) == match->vendor_id)

The problem I'm having is this. If all the 1s in the descriptor.idVendor
match the 1s in the vendor_id I'm looking for, it will register as a match
when in fact they are different IDs. I can work around this by taking
advantage of the custom match function but wanted to run this by somebody.

Thanks.

-- 

Arnold
_______________________________________________
libhid-discuss mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/libhid-discuss

Reply via email to