From c45d4e685a4fdf2fe84a295d296af82ee8a7894c Mon Sep 17 00:00:00 2001 From: Romuald Conty Date: Wed, 25 May 2011 10:15:18 +0000 Subject: [PATCH] pn53x_usb: continue to search a available device on usb errors (ie. Device Busy) --- libnfc/drivers/pn53x_usb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libnfc/drivers/pn53x_usb.c b/libnfc/drivers/pn53x_usb.c index 2a102da..90e89ab 100644 --- a/libnfc/drivers/pn53x_usb.c +++ b/libnfc/drivers/pn53x_usb.c @@ -280,7 +280,7 @@ pn53x_usb_connect (const nfc_device_desc_t *pndd) } usb_close (data.pudh); // we failed to use the specified device - return NULL; + continue; } res = usb_claim_interface (data.pudh, 0); @@ -288,7 +288,7 @@ pn53x_usb_connect (const nfc_device_desc_t *pndd) DBG ("Can't claim interface (%s)", strerror (-res)); usb_close (data.pudh); // we failed to use the specified device - return NULL; + continue; } data.model = pn53x_usb_get_device_model (dev->descriptor.idVendor, dev->descriptor.idProduct); // Allocate memory for the device info and specification, fill it and return the info