USBHOST: fix call back

pull/3432/head
Michel Jaouen 2016-12-06 11:59:42 +01:00
parent 1577037b4b
commit 48434cfd64
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

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