]> git.zerfleddert.de Git - proxmark3-svn/blobdiff - client/cmdhfmf.c
Update cmdhf14a.c
[proxmark3-svn] / client / cmdhfmf.c
index 28198876991a750885e0993c0be76464af9a1e18..d909cd8c8f9e1fa690ad93871955c0381d53e5a4 100644 (file)
@@ -19,6 +19,7 @@
 #include "cmdmain.h"\r
 #include "cmdhfmfhard.h"\r
 #include "util.h"\r
+#include "util_posix.h"\r
 #include "usb_cmd.h"\r
 #include "ui.h"\r
 #include "mifarehost.h"\r
@@ -905,7 +906,7 @@ int CmdHF14AMfChk(const char *Cmd)
        char filename[FILE_PATH_SIZE]={0};\r
        char buf[13];\r
        uint8_t *keyBlock = NULL, *p;\r
-       uint8_t stKeyBlock = 20;\r
+       uint16_t stKeyBlock = 20;\r
        \r
        int i, res;\r
        int     keycnt = 0;\r
@@ -970,6 +971,7 @@ int CmdHF14AMfChk(const char *Cmd)
                break;\r
        default:\r
                PrintAndLog("Key type must be A , B or ?");\r
+               free(keyBlock);\r
                return 1;\r
        };\r
        \r
Impressum, Datenschutz