From 93e323d890c1912c756c9b4d3b4484655832c7e8 Mon Sep 17 00:00:00 2001 From: sh7d <47714037+sh7d@users.noreply.github.com> Date: Sat, 7 Sep 2019 19:41:48 +0200 Subject: [PATCH] Review requested changes --- client/cmdhfmf.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/client/cmdhfmf.c b/client/cmdhfmf.c index b74a5af3a..90501943b 100644 --- a/client/cmdhfmf.c +++ b/client/cmdhfmf.c @@ -1660,7 +1660,7 @@ static int CmdHF14AMfAutoPWN(const char *Cmd) { // Settings bool slow = false; bool legacy_mfchk = false; - int prng_type = 0; + int prng_type = PM3_EUNDEF; bool verbose = false; bool has_filename = false; bool errors = false; @@ -1776,11 +1776,12 @@ static int CmdHF14AMfAutoPWN(const char *Cmd) { } } - // card prng type (weak=1 / hard=0 / select/card comm error fail = -vaule) + // card prng type (weak=1 / hard=0 / select/card comm error = negative value) prng_type = detect_classic_prng(); if (prng_type < 0){ PrintAndLogEx(FAILED, "\nNo tag detected or other tag communication error"); - goto noValidKeyFound; + free(e_sector); + return prng_type; } // print parameters