nfc_initiator_select_dep_target() function returns nox libnf error code and fix some uses of nfc_initiator_transceive_bytes() function.

This commit is contained in:
Audrey Diacre 2011-12-21 09:15:44 +00:00
parent 0f5cc5683d
commit c41d7de8ca
12 changed files with 58 additions and 57 deletions

View file

@ -400,8 +400,8 @@ main (int argc, char *argv[])
if (!target_only_mode) {
// Forward the frame to the original tag
ret = nfc_initiator_transceive_bytes
(pndInitiator, abtCapdu, szCapduLen, abtRapdu, &szRapduLen, 0);
ret = (nfc_initiator_transceive_bytes
(pndInitiator, abtCapdu, szCapduLen, abtRapdu, &szRapduLen, 0) < 0) ? 0 : 1;
} else {
if (scan_hex_fd3(abtRapdu, &szRapduLen, "R-APDU") != EXIT_SUCCESS) {
fprintf (stderr, "Error while scanning R-APDU from FD3\n");