USBHOST: fix call back

pull/3755/head
Michel Jaouen 2016-12-06 11:59:42 +01:00 committed by Martin Kojtal
parent 13feab6dc3
commit e27b7e6fa3
2 changed files with 3 additions and 2 deletions

View File

@ -94,7 +94,7 @@ void USBDeviceConnected::init(uint8_t hub_, uint8_t port_, bool lowSpeed_) {
void USBDeviceConnected::disconnect() {
for(int i = 0; i < MAX_INTF; i++) {
intf[i].detach.call();
if (intf[i].detach) intf[i].detach.call();
}
init();
}

View File

@ -105,6 +105,7 @@ public:
* Call the handler associted to the end of a transfer
*/
inline void call() {
if (rx)
rx.call();
};