mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-10 05:35:20 -05:00
clean up some debugging output.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17871 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
1c9e1bc17c
commit
c3400684f1
1 changed files with 2 additions and 6 deletions
|
|
@ -268,17 +268,13 @@ QMap<uint32_t, QString> Detect::listUsbDevices(void)
|
|||
break;
|
||||
}
|
||||
}
|
||||
qDebug() << "SetupDiGetDeviceRegistryProperty" << description << QString::fromWCharArray(buffer);
|
||||
|
||||
unsigned int vid, pid, rev;
|
||||
if(_stscanf(buffer, _TEXT("USB\\Vid_%x&Pid_%x&Rev_%x"), &vid, &pid, &rev) != 3) {
|
||||
qDebug() << "Error getting USB ID -- possibly no USB device";
|
||||
}
|
||||
else {
|
||||
if(_stscanf(buffer, _TEXT("USB\\Vid_%x&Pid_%x&Rev_%x"), &vid, &pid, &rev) == 3) {
|
||||
uint32_t id;
|
||||
id = vid << 16 | pid;
|
||||
usbids.insert(id, description);
|
||||
qDebug("VID: %04x PID: %04x", vid, pid);
|
||||
qDebug("VID: %04x, PID: %04x", vid, pid);
|
||||
}
|
||||
if(buffer) free(buffer);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue