Skip Menu |

This queue is for tickets about the Device-USB CPAN distribution.

Report information
The Basics
Id: 20397
Status: resolved
Estimated: 15 min
Worked: 15 min
Priority: 0/
Queue: Device-USB

People
Owner: cpan.wade [...] anomaly.org
Requestors: jmt [...] c3po.es
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.13
Fixed in: 0.14



Subject: Wrapper doesn't get bInterfaceClass correctly
Hello, First of all, thanks for this wrapper. Wrapper doesn't get bInterfaceClass correctly, since it assigns it to bInterfaceNumber. This makes impossible to search devices by their interface class. I can reproduce this problem under version 0.13 I attach a patch that solves the problem. Regards, Josep Monés Teixidor
Subject: binterfaceclass_is_not_binterfacenumber.diff
diff -Naur Device-USB-0.13.old/lib/Device/USB.pm Device-USB-0.13/lib/Device/USB.pm --- Device-USB-0.13.old/lib/Device/USB.pm 2006-05-19 04:20:14.000000000 +0200 +++ Device-USB-0.13/lib/Device/USB.pm 2006-07-10 18:20:31.000000000 +0200 @@ -622,7 +622,7 @@ hashStoreInt( hash, "bInterfaceNumber", inter->bInterfaceNumber ); hashStoreInt( hash, "bAlternateSetting", inter->bAlternateSetting ); hashStoreInt( hash, "bNumEndpoints ", inter->bNumEndpoints ); - hashStoreInt( hash, "bInterfaceNumber", inter->bInterfaceClass ); + hashStoreInt( hash, "bInterfaceClass", inter->bInterfaceClass ); hashStoreInt( hash, "bInterfaceSubClass", inter->bInterfaceSubClass ); hashStoreInt( hash, "bInterfaceProtocol", inter->bInterfaceProtocol ); hashStoreInt( hash, "iInterface", inter->iInterface ); diff -Naur Device-USB-0.13.old/USB.pm Device-USB-0.13/USB.pm --- Device-USB-0.13.old/USB.pm 2006-05-19 04:20:14.000000000 +0200 +++ Device-USB-0.13/USB.pm 2006-07-10 18:20:50.000000000 +0200 @@ -622,7 +622,7 @@ hashStoreInt( hash, "bInterfaceNumber", inter->bInterfaceNumber ); hashStoreInt( hash, "bAlternateSetting", inter->bAlternateSetting ); hashStoreInt( hash, "bNumEndpoints ", inter->bNumEndpoints ); - hashStoreInt( hash, "bInterfaceNumber", inter->bInterfaceClass ); + hashStoreInt( hash, "bInterfaceClass", inter->bInterfaceClass ); hashStoreInt( hash, "bInterfaceSubClass", inter->bInterfaceSubClass ); hashStoreInt( hash, "bInterfaceProtocol", inter->bInterfaceProtocol ); hashStoreInt( hash, "iInterface", inter->iInterface );