From da2aa2c55fb7bfca0e0c75ff91775456ae4edea0 Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Wed, 17 Apr 2019 14:50:07 +0200 Subject: [PATCH] test fix --- client/emv/cmdemv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/emv/cmdemv.c b/client/emv/cmdemv.c index 041ad73ee..c3d569b42 100644 --- a/client/emv/cmdemv.c +++ b/client/emv/cmdemv.c @@ -287,7 +287,8 @@ static int CmdEMVGPO(const char *Cmd) { PrintAndLogEx(ERR, "Can't create PDOL data."); tlvdb_free(tmp_ext); tlvdb_free(tlvRoot); - free(data_tlv); + if ( pdol_data_tlv != &data_tlv); + free(pdol_data_tlv); return 4; } PrintAndLogEx(INFO, "PDOL data[%d]: %s", pdol_data_tlv_data_len, sprint_hex(pdol_data_tlv_data, pdol_data_tlv_data_len));