Fix internal current target when using nfc_initiator_poll_target() (Thanks to Bjoern Kinscher)
Fixes Issue 265.
This commit is contained in:
parent
b7f590acc8
commit
e5c732e181
1 changed files with 6 additions and 0 deletions
|
@ -1209,10 +1209,16 @@ pn53x_initiator_poll_target(struct nfc_device *pnd,
|
|||
switch (res) {
|
||||
case 1:
|
||||
*pnt = ntTargets[0];
|
||||
if (pn53x_current_target_new(pnd, pnt) == NULL) {
|
||||
return pnd->last_error = NFC_ESOFT;
|
||||
}
|
||||
return res;
|
||||
break;
|
||||
case 2:
|
||||
*pnt = ntTargets[1]; // We keep the selected one
|
||||
if (pn53x_current_target_new(pnd, pnt) == NULL) {
|
||||
return pnd->last_error = NFC_ESOFT;
|
||||
}
|
||||
return res;
|
||||
break;
|
||||
default:
|
||||
|
|
Loading…
Add table
Reference in a new issue