Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Haberler committed Dec 13, 2023
1 parent 5232e35 commit 2f6b156
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/MFRC522Extended.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,7 @@ MFRC522::StatusCode MFRC522Extended::TCL_Transceive(TagInfo *tag, byte *sendData
// Swap block number on success
tag->blockNumber = !tag->blockNumber;

if (backData && (backLen > 0)) {
if (backData && (backLen != nullptr)) {
if (*backLen < in.inf.size)
return StatusCode::STATUS_NO_ROOM;

Expand All @@ -837,10 +837,10 @@ MFRC522::StatusCode MFRC522Extended::TCL_Transceive(TagInfo *tag, byte *sendData
byte ackDataSize = FIFO_SIZE;
byte linked = 0;
result = TCL_TransceiveRBlock(tag, true, ackData, &ackDataSize, &linked);
if (result != STATUS_OK)
if (result != StatusCode::STATUS_OK)
return result;

if (backData && (backLen > 0)) {
if (backData && (backLen != nullptr)) {
if ((*backLen + ackDataSize) > totalBackLen)
return StatusCode::STATUS_NO_ROOM;

Expand Down

0 comments on commit 2f6b156

Please sign in to comment.