summaryrefslogtreecommitdiffstats
path: root/src/phLibNfc_ndef_raw.c
diff options
context:
space:
mode:
authorMartijn Coenen <martijn.coenen@nxp.com>2010-11-01 17:36:37 -0600
committerNick Pelly <npelly@google.com>2010-11-02 12:16:58 -0500
commitbcd4097d93d61a86839412879f9ccf4ed303ee15 (patch)
treeb881b991fb0529eda8a017934a3e359414d1e7b9 /src/phLibNfc_ndef_raw.c
parentfa199fc046cb0bc698d564daaba669a180b7c6f4 (diff)
downloadexternal_libnfc-nxp-bcd4097d93d61a86839412879f9ccf4ed303ee15.zip
external_libnfc-nxp-bcd4097d93d61a86839412879f9ccf4ed303ee15.tar.gz
external_libnfc-nxp-bcd4097d93d61a86839412879f9ccf4ed303ee15.tar.bz2
Fixed Mifare classic presence checking
Change-Id: I7a1c90f46e669093e7c2d8778d712eeb6e6b7917 Signed-off-by: Nick Pelly <npelly@google.com>
Diffstat (limited to 'src/phLibNfc_ndef_raw.c')
-rw-r--r--src/phLibNfc_ndef_raw.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/phLibNfc_ndef_raw.c b/src/phLibNfc_ndef_raw.c
index a208f32..1392895 100644
--- a/src/phLibNfc_ndef_raw.c
+++ b/src/phLibNfc_ndef_raw.c
@@ -284,6 +284,10 @@ void phLibNfc_Ndef_Read_Cb(void* Context,NFCSTATUS status)
else
{
gpphLibContext->status.GenCb_pending_status = FALSE;
+ if (gpphLibContext->psBufferedAuth != NULL && gpphLibContext->ndef_cntx.psNdefMap != NULL) {
+ gpphLibContext->psBufferedAuth->addr = (uint8_t)
+ gpphLibContext->ndef_cntx.psNdefMap->StdMifareContainer.currentBlock;
+ }
if(NFCSTATUS_FAILED == status )
{
@@ -521,6 +525,10 @@ void phLibNfc_Ndef_Write_Cb(void* Context,NFCSTATUS status)
else
{
gpphLibContext->status.GenCb_pending_status = FALSE;
+ if (gpphLibContext->psBufferedAuth != NULL && gpphLibContext->ndef_cntx.psNdefMap != NULL) {
+ gpphLibContext->psBufferedAuth->addr = (uint8_t)
+ gpphLibContext->ndef_cntx.psNdefMap->TLVStruct.NdefTLVBlock;
+ }
if(status == NFCSTATUS_FAILED )
{
status = NFCSTATUS_FAILED;