fixed param_gethex_to_eol

This commit is contained in:
merlokk 2017-11-28 14:58:32 +02:00
commit f981044703
2 changed files with 5 additions and 3 deletions

View file

@ -744,9 +744,9 @@ int CmdHF14AAPDU(const char *cmd) {
CLIParserFree(); CLIParserFree();
return 1; return 1;
} }
CLIParserFree(); CLIParserFree();
// PrintAndLog("---str [%d] %s", astr->count, astr->sval[0]); // PrintAndLog("---str [%d] %s", arg_get_str(4)->count, arg_get_str(4)->sval[0]);
PrintAndLog(">>>>[%s%s%s] %s", activateField ? "sel ": "", leaveSignalON ? "keep ": "", decodeTLV ? "TLV": "", sprint_hex(data, datalen)); PrintAndLog(">>>>[%s%s%s] %s", activateField ? "sel ": "", leaveSignalON ? "keep ": "", decodeTLV ? "TLV": "", sprint_hex(data, datalen));

View file

@ -498,8 +498,10 @@ int param_gethex_to_eol(const char *line, int paramnum, uint8_t * data, int maxd
int indx = bg; int indx = bg;
while (line[indx]) { while (line[indx]) {
if (line[indx] == '\t' || line[indx] == ' ') if (line[indx] == '\t' || line[indx] == ' ') {
indx++;
continue; continue;
}
if (isxdigit(line[indx])) { if (isxdigit(line[indx])) {
buf[strlen(buf) + 1] = 0x00; buf[strlen(buf) + 1] = 0x00;