diff --git a/examples/nfc-anticol.c b/examples/nfc-anticol.c index 8d6921f..0fa4e03 100644 --- a/examples/nfc-anticol.c +++ b/examples/nfc-anticol.c @@ -83,7 +83,7 @@ transmit_bits(const uint8_t *pbtTx, const size_t szTxBits) print_hex_bits(pbtTx, szTxBits); } // Transmit the bit frame command, we don't use the arbitrary parity feature - if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, NULL)) < 0) + if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, sizeof(abtRx), NULL)) < 0) return false; // Show received answer diff --git a/examples/nfc-mfsetuid.c b/examples/nfc-mfsetuid.c index d1b5b14..5c23785 100644 --- a/examples/nfc-mfsetuid.c +++ b/examples/nfc-mfsetuid.c @@ -95,7 +95,7 @@ transmit_bits(const uint8_t *pbtTx, const size_t szTxBits) print_hex_bits(pbtTx, szTxBits); } // Transmit the bit frame command, we don't use the arbitrary parity feature - if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, NULL)) < 0) + if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, sizeof(abtRx), NULL)) < 0) return false; // Show received answer diff --git a/examples/nfc-relay.c b/examples/nfc-relay.c index be30585..b728c57 100644 --- a/examples/nfc-relay.c +++ b/examples/nfc-relay.c @@ -205,7 +205,7 @@ main(int argc, char *argv[]) } // Forward the frame to the original tag if ((szTagRxBits = nfc_initiator_transceive_bits - (pndReader, abtReaderRx, (size_t) szReaderRxBits, abtReaderRxPar, abtTagRx, abtTagRxPar)) > 0) { + (pndReader, abtReaderRx, (size_t) szReaderRxBits, abtReaderRxPar, abtTagRx, sizeof(abtTagRx), abtTagRxPar)) > 0) { // Redirect the answer back to the reader if (nfc_target_send_bits(pndTag, abtTagRx, szTagRxBits, abtTagRxPar) < 0) { nfc_perror(pndTag, "nfc_target_send_bits"); diff --git a/libnfc/nfc.c b/libnfc/nfc.c index 7c12087..48fb2ea 100644 --- a/libnfc/nfc.c +++ b/libnfc/nfc.c @@ -120,7 +120,7 @@ nfc_init(nfc_context *context) /** @ingroup lib * @brief Deinitialize libnfc. * Should be called after closing all open devices and before your application terminates. - *@param context The context to deinitialize + * @param context The context to deinitialize */ void nfc_exit(nfc_context *context) @@ -684,6 +684,7 @@ nfc_initiator_transceive_bits(nfc_device *pnd, uint8_t *pbtRx, const size_t szRx, uint8_t *pbtRxPar) { + (void)szRx; HAL(initiator_transceive_bits, pnd, pbtTx, szTxBits, pbtTxPar, pbtRx, pbtRxPar); } @@ -764,6 +765,7 @@ nfc_initiator_transceive_bits_timed(nfc_device *pnd, uint8_t *pbtRxPar, uint32_t *cycles) { + (void)szRx; HAL(initiator_transceive_bits_timed, pnd, pbtTx, szTxBits, pbtTxPar, pbtRx, pbtRxPar, cycles); } diff --git a/utils/nfc-mfclassic.c b/utils/nfc-mfclassic.c index 79f14e5..e3dc96f 100644 --- a/utils/nfc-mfclassic.c +++ b/utils/nfc-mfclassic.c @@ -98,7 +98,7 @@ transmit_bits(const uint8_t *pbtTx, const size_t szTxBits) printf("Sent bits: "); print_hex_bits(pbtTx, szTxBits); // Transmit the bit frame command, we don't use the arbitrary parity feature - if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, NULL)) < 0) + if ((szRxBits = nfc_initiator_transceive_bits(pnd, pbtTx, szTxBits, NULL, abtRx, sizeof(abtRx), NULL)) < 0) return false; // Show received answer