From c30e282f5ebffdf46c234712533d2bc66294f596 Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Sun, 18 Mar 2018 21:18:26 +0100 Subject: [PATCH] chg: 'trace list' - allocating memory --- client/cmdtrace.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/cmdtrace.c b/client/cmdtrace.c index 959f7d1f6..92c94fdc3 100644 --- a/client/cmdtrace.c +++ b/client/cmdtrace.c @@ -448,7 +448,6 @@ int CmdTraceList(const char *Cmd) { } else { str_lower(type); - PrintAndLogEx(WARNING, "to lower"); // validate type of output if (strcmp(type, "iclass") == 0) protocol = ICLASS; @@ -473,10 +472,11 @@ int CmdTraceList(const char *Cmd) { //Validations if (errors) return usage_trace_list(); - uint16_t tracepos = 0; + // reserv some space. + trace = malloc(USB_CMD_DATA_SIZE); - if ( !isOnline ) { + if ( isOnline ) { // Query for the size of the trace UsbCommand response; GetFromBigBuf(trace, USB_CMD_DATA_SIZE, 0);